feat(sophora-components): Alternative build setup / clientside-only rendering#343
Merged
feat(sophora-components): Alternative build setup / clientside-only rendering#343
Conversation
Contributor
Author
243ef87 to
1ee7fcc
Compare
b84d7b4 to
b404424
Compare
6ccf03f to
2e02957
Compare
a0694d5 to
261feaa
Compare
c769791 to
144e8a8
Compare
144e8a8 to
cb8ec47
Compare
cb8ec47 to
4a41d66
Compare
awesomephant
requested changes
Apr 2, 2026
Collaborator
awesomephant
left a comment
There was a problem hiding this comment.
lgtm following offline discussion and pending changes below
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Use plain Svelte and Vite for rendering generic components in Sophora (Datawrapper switcher, highlight cards) without SvelteKit. Rendering is client-side only – which is fine, because there is no meaningful server-side rendering anyways.
Production demo
Pro:
<script type="module">only being loaded and evaluated once per document, even when referenced multiple times.Con:
@swr-data-lab/componentsbuilds upon some SvelteKit-only environment variablesCloses #330