Hello everyone! Last week I had the chance to chat with Grégoire Hertault, French developer and creator of the React Native Twilio Phone module, a module for managing VoIP on mobile. He told me more about this project through an exchange that I am sharing with you here.
Who are you, Grégoire?
Valériane: Hello, can you introduce yourself for our readers?
Grégoire: I am Grégoire Hertault, developer since 2010, fullstack for 4 years. By fullstack I mean: backend, frontend, cloud and ops.
I have also been a freelance for 4 years, and normally I work with clients for service assignments.
But this year I decided to take a break and create my own app. I've been on it since January, it's a personal project, independent of the current health situation. It is an application for contacting customer services.
It was while developing it that I realized that I needed certain libraries that were not available on GitHub. This is what led me to develop two libraries, one on AWS Amplifyy and React and the other on Twilio Voice and React Native.
V: Since when have you been coding in React Native and what do you like about this language and / or the mobile development ecosystem?
G: For me, coding in React Native is very new. I had been doing technical watches and knew a bit but I really dove into it in January of this year, for my application purposes.
What I like is summed up very well by its slogan: “code once, deliver everywhere”. With a single code base we can have an iOS and an Android application, and we can even go further with the modules to develop under Mac OS and Windows. It's really that aspect, with unique code for all platforms that I really like.
I am also very enthusiastic about the React framework which is quite powerful and pleasant to use.
React Native Twilio Phone module
V: Can you summarize your module in one sentence?
G: It is a library that allows you to implement voice over IP with Android and iOS using the Twilio Voice API.
V: How did you get the idea of creating this module?
G: While developing my application, I looked for the open source modules that support VoIP and found a few but quite old, or even not maintained at all. As I analyzed their code, I realized that some have a bias that is no longer correct today. These are libraries that manage absolutely everything, notification, call display, call reception whether the app is in the background or foreground ... This “all in one” format is complex to maintain.
On the other hand, I have found some maintained libraries that only handle small parts like push notification or others that only handle call display with native user interfaces be it Android or iOS.
But even by assembling several recent libraries and meeting my needs, I was still missing the VoIP part.
This is how I came across the Twilio Voice API, via a web search.
V: What made you want to develop on the Twilio platform?
G: I liked cloud tools, I know AWS very well and when I came across Twilio I had the same feeling: that it was a huge platform, which would meet my needs, not too expensive, reliable and which opened up lots of technical possibilities.
I found that it was easy to call thanks to Twilio Studio. The tool is powerful and the documentation is very comprehensive.
It is this lack that prompted me to create this module for React Native! But in the end, I'm very happy I did.
Feedback on the creation of the module
[React Native Twilio Phone on GitHub]
V: How did the creation of the library go?
G: Creating this module was a necessity for my project, but overall it was fun to do.
There is very good documentation on the React Native side to get started in module development. In particular, there is a project maintained by a team of framework experts called React Native Bob. This is a bootstrap project, which allows you to run
$ react-native bob in your terminal, which generates a project containing everything you need to start developing. I found it simple and intuitive and above all it allowed me to be able to go directly to a module in Swift for iOS and Kotlin for Android.
For the native development part of the module, since I have the basics of programming, Kotlin and Swift were not very hard to learn. They are pretty neutral and cool languages.
I found the IDEs to be very nice, especially Android Studio. You give it a piece of code in Java and it offers you the equivalent in Kotlin. And if there is an error it is very accurate, especially for linking to problematic code, perfect for debugging!
Regarding the part with the Twilio Voice API, I relied on the documentation of the two SDKs, Android and iOS and I read the code a lot by following what they had done in the Twilio quickstarts for Android and iOS.
With all that, it went very well, it allowed me to not have any blockages and to always find the info I wanted.
V: Is it possible to contribute to your module?
G: Yes, of course, all the information to contribute to my project is here.
A big thank you to Grégoire for his availability and good humor. I loved hearing the story behind his module’s creation and hope you enjoyed reading it as much as I did heard it.
I can't wait to see what you build!
Valériane Venance is Developer Evangelist at Twilio. Please feel free to contact her via firstname.lastname@example.org if you have created a tool you would like to share on the Twilio blog!