Web
To test your code and view HTML card previews, use DivKit Web Playground. DivKit Web Playground has a library with samples of various elements: you can edit the code of any sample and display the result in the browser or on the screen of a mobile device.
To create an HTML card preview:
- On the left side of the page, add the card prototype code in JSON or TypeScript format.
- To use ready-made samples, click Samples and select an item from the library. You can edit and refine the samples.
- On the right side of the page, select the resolution and type of screen for which the card prototype will be displayed. If there are errors in the code, they will be displayed in the Errors section under the card preview.
- To open the card structure, click Structure in the lower right corner.
View the result on your device
To view the result of a JSON change in an Android or iOS app, link the editor to it:
-
Install the DivKit Playground app for Android or iOS on your device.
-
Select demo.
-
In DivKit Web Playground, click Share.
-
In the Android app, tap and scan the QR code or paste the address from the Link to json field.
Learn more
Follow DivKit news in the Telegram channel: http://t.me/divkit_news
You can also discuss topics of interest in the DivKit user community in Telegram: https://t.me/divkit_community_ru