-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom Content Types #110
Comments
High level, supporting custom content types in RN looks a little like this:
|
I know there was a discussion about this earlier that I missed, but why not just ship bytes out of iOS/Kotlin and handle all encoding/decoding in JS? |
The short answer is for performance. I sometimes forget that content types doesn't just mean "a little meta data on a reply" -- it also means large files with complicated encryption and rendering schemes.
Performance was the driving reason but I do think there's also an API/SDK design rationale that holds here too: react native is not a web context and developers are mislead trying to treat it that way. Native apps really do have fundamentally different architectures and expectations from web apps. The browser does a lot for you and your webpage doesn't run in your pocket. And IMO |
Totally agree! However I guess for "simple content types" that are basically some metadata, being able to code them in JS then use them in RN would be nice - and that would probably work as @neekolas said: just ship bytes out and do the work in JS. This might be subperformant in some cases but would make all content types available in RN which would also have great value - I guess that's exactly the goal of this task so we're on the right path! |
Implemented in #155 |
It would be nice to be able to create custom content types in react native like we do in the other sdks.
The text was updated successfully, but these errors were encountered: