Are there any instruments to watch screen layout in React Native without running app? - react-native

I familiarized with Android development and started to read some information about React Native. And one of the problem which I faced with is that I can't see the screen layout.
In Android Studio, for example, I could see the design of my XML layout without running app. Maybe there are such instruments in React Native, but I didn't see them in WebStorm nor VSCode. Maybe I am wrong and they exist, so, can you help me to find them in such situation?

Some modules format the xml document in vscode,
but others have previewable tools.
XML TOOLS
Extension Settings
xmlTools.enableXmlTreeView: Enables the XML Tree View for XML
documents.
xmlTools.enableXmlTreeViewMetadata: Enables attribute and child
element counts in the XML Document view.
xmlTools.enableXmlTreeViewCursorSync: Enables auto-reveal of
elements in the XML Document view when a start tag is clicked in the
editor.
xmlTools.enforcePrettySelfClosingTagOnFormat: Ensures a space is
added before the forward slash at the end of a self-closing tag.
...

I also had the same problem where there is no layout view in VSCode like in Android Studio. My suggestion is to mock out your View containers with coloured boxes. This is an example of designing a screen's header, so I'm making sure the spacing and sizing is all good:

Related

Compose Desktop: How to Access Extended Material Icon Set?

I am making an app using Compose for Desktop. I am trying to include a simple file download Icon that I know is included in the lengthy set of Material Icons, however it is not available under Icons.Filled. Some of the icons included, in my opinion, are nowhere near as commonly used as download... go figure.
I know that Compose for Android has a dependency for an extended set of Material Icons. I tried adding that dependency to my Desktop app, but it threw errors at me.
For now I have added a Feather Icons set courtesy of DevSrSouza, but I would like to know if there is a way to access the Material Icons extension in Compose for Desktop? Thanks.
I guess you have already found the answer but I also had this problem for long time, so here is a right dependency for compose desktop: "org.jetbrains.compose.material:material-icons-extended-desktop:$compose_version"

React native unrecognized font family using external Svg

I'm implementing a react native app (with expo, I don't know if this can be relevant). In this app I'm sending an ajax request to an external service and that service returns a list of URLs related to images in svg format that I need to show in my app.
To show the images I'm using react-native-svg library (I've tried with Svg/Image and with SvgUri). Generally it work properly, but there is some SVG that break my app, because it includes a font-family not supported by my react-native project and the iOS simulator is showing me the error: Unrecognized font family '<FONT-FAMILY-NAME>'.
I've already checked several post on stackoverflow and they all suggest to add the specific font-family to the project, but this solution will not fix my issue in log term as in future I can receive a new SVG file with a different font that will break again my app. I obviously have absolutely no control on the SVG provided by the external service. So, what I'm interested to know is:
Is there any way to add dynamically a font-family to react-native project? For dynamically I mean that the app will add the font to its list when it's required by the SVG file
By using Svg/Image (or with SvgUri) is there any way I can overwrite the font to avoid it to break the app?
Thanks in advance for your answers.

Are there some PDF display plagins for React native expo

I am working on an e-library project, where we have to display pdf books for children.
I would like to know if I can find some PDF plugins to display PDF nicely.
I used to have the same problem and I figured out, that Android works very well with rn-pdf-reader-js. On the other hand, for ios WebView component is 100% sufficient to display PDF content, so I switched (depends on the platform) between the two of them.

How to create a custom chart with Appcelerator Titanium (Alloy) for Android

How I create a custom chart like this
with Titanium's Alloy elements (xml, tss, js - no SVG or canvas)? Any suggestion?
One approach which worked for me was the using of a webview and Google Charts.
I stored my "skeleton html page" as local asset, and inside it I wrote the minimum necessary javascript to get the json (from the controller) and to draw the chart.
I didn't need to show data offline so I directly linked the online library but I'm almost sure it's possible to use it offline too.
https://developers.google.com/chart/

How to parse markdown in react-native (esp. android)?

Since React Native webview components is only support iOS, I wonder what other options are available to parse markdown strings for android. Anyone had worked with markdown in React Native for Android app?
See if this solves the problem: https://github.com/lwansbrough/react-native-markdown
I recommend react-native-markdown-view which we're using at 2minute.com.
It's the only RN Markdown lib I found that properly renders a list. It's also the only one to have merged a pull request in the last month.
Alternatives: I've tried others in some depth but they can't do lists properly. react-native-simple-markdown renders the list bullet in the middle instead of at the top of the list item, and the styling was also bugged. react-native-markdown-renderer renders lists off the right side of the screen. react-native-markdown hasn't been touched in 3 years so I skipped that one.