-
Notifications
You must be signed in to change notification settings - Fork 119
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
generic question on building a library on top of material bread? #313
Comments
That's an awesome experiment, glad you found Material Bread so useful!
RNW, in a general sense, is just translating React Native to React DOM, so you can integrate React Native Web components and regular React components in the same web app. Both https://material-bread.org/ and https://www.reactnativeinfinity.com/ use some CSS, HTML markup, other web specific libraries along side Material Bread components and React Native components. But ultimately I think it depends on how much code sharing you want and how much you're willing to configure your web app. Web depends on RN and RNW Web depends on React Native but uses many web apis Web doesn't depend on React Native
I think this is a perfect use case for sharing the same component across both platforms, if the search is the same on both (with minor differences), then I'd just create one library |
Hi thanks for the clarification. Yes, I think we will have to go with a separate web version. There is like 10-15 existing CRA apps, and looking at the setup, they would also have to eject in order to modify those babel loader rules, correct? |
There are a few packages that allow custom webpack rules for CRA apps necolas/react-native-web#1192, for example https://github.com/timarney/react-app-rewired, but they're not officially supported by the React team. |
Yeah, the teams were in that situation before where everbody was using their own build versions, some CRAs, some custom, some rewired. It was causing too many inconsistencies when adding shared libraries "cross-apps" - exactly like just right now with the enterprise search, hence decision was made to standardize on CRA and material-ui. |
Hi,
First of all thank you for this amazing library.
We are doing some quick prototyping of native kits - between nativebase, native elements, kitten etc. We gave each kit one day to see how much we can produce, and native version of material bread is a clear winner - excellent documentation and great examples. Real cudos for great work!
This is now forcing us to re-evaluate if we should also consider it for web. We have originally decided to go with standard material-ui.com + some extra 3rd party libs.
To clarify, we are building an internaly library, not an app, to be given to different departments.
So if we build a set of components on top of material-bread - for ex. "material-bread-search", will it be possible to publish/produce just a standard web-only library version to give to another department that already has a web-app and doesnt care anything about native or native web (i.e. they already have CRA running and building and publishing their app and just want to do for ex. yarn add 'material-bread-search' - or will they also have to 'buy-in' fully to switching to react native for web under the hood? They already use material-ui.com, so of course we would have to take care of theming the material bread to match what they have.
Similary, we can give just the library to native team who doesnt care anything about the web (its a completelly different app, but needs the same search)
And some 3rd department that needs both we can fully unify i.e. via your https://www.reactnativeinfinity.com/.
Even if not possible right now but yes in theory, please let us know any insights you might have.
Thanks again
The text was updated successfully, but these errors were encountered: