[v2] Generate permalink to specific JSX in REPL demo #149
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As same as Block Kit Builder, REPL demo in v2 will generate a specific permalink to edited JSX. Developer will become easy to do prototyping and sharing through jsx-slack REPL.
jsx:
prefixA generated link will have a hash prefixed with
#jsx:
such as#jsx:XXXXXXXXX....
: The encoded string of compressed JSX data by URL-safe Base64 encoding.For example, this JSX generates https://speee-jsx-slack.netlify.app/#jsx:eJyzccrJT84utuNSULAJTk0uyczPA7EVFDxSc3LydRRskuzK84tyUmz0k-wUQYr04aps9KF6AbQEFEU=.
bkb:
prefixBy prepending extra prefix
bkb:
to hash, REPL demo will try to redirect into Block Kit Builder with parameters generated by the converted JSON. e.g. https://speee-jsx-slack.netlify.app/#bkb:modalIt also can use together with
jsx:
prefix as like https://speee-jsx-slack.netlify.app/#bkb:jsx:eJyzccrJT84utuNSULAJTk0uyczPA7EVFDxSc3LydRRskuzK84tyUmz0k-wUQYr04aps9KF6AbQEFEU=.It's useful for replacing "Preview in Slack Block Kit Builder" buttons on the documentation. They have URLs for Block Kit Builder generated in advance, but won't reflect the change of jsx-slack so we had to update URL manually when changed behavior of components. We do no longer have to worry the updation of examples by using
bkb:
prefix.