jamespatrickgibson / union Goto Github PK
View Code? Open in Web Editor NEWA design system boilerplate for Svelte & CSS
Home Page: http://www.designwithunion.com
A design system boilerplate for Svelte & CSS
Home Page: http://www.designwithunion.com
Using the svelte quickstart, importing and using the union-design-system npm package the npm run dev
command returns this error:
[!] Error: Could not load /Users/upstateinteractive/code/personal/website-/node_modules/union-design-system/src/index.js (imported by src/App.svelte): ENOENT: no such file or directory, open '/Users/upstateinteractive/code/personal/website-/node_modules/union-design-system/src/index.js'
<script>
export let name;
import {
Button,
FixedImage,
Frame,
Link,
List,
ListItem,
Navigation,
NavigationSection,
MediaObject,
Stack,
SplitView,
Text,
} from "union-design-system";
</script>
<style>
main {
text-align: center;
padding: 1em;
max-width: 240px;
margin: 0 auto;
}
h1 {
color: #ff3e00;
text-transform: uppercase;
font-size: 4em;
font-weight: 100;
}
@media (min-width: 640px) {
main {
max-width: none;
}
}
</style>
<Navigation>
<NavigationSection title="Apple Music">
<List>
<ListItem>
<Text size="3">
<Link to="./" type="implied">For You</Link>
</Text>
</ListItem>
<ListItem>
<Text size="3">
<Link to="./" type="implied">Browse</Link>
</Text>
</ListItem>
<ListItem>
<Text size="3">
<Link to="./" type="implied">Radio</Link>
</Text>
</ListItem>
</List>
</NavigationSection>
</Navigation>
<main>
<h1>Hello {name}!</h1>
<p>
Visit the
<a href="https://svelte.dev/tutorial">Svelte tutorial</a>
to learn how to build Svelte apps.
</p>
</main>
I compiled snippets of source from three places:
the lightly annotated code is here.
...the angular example-viewer is a tightly-coupled system. Angular docs use a pre-processor, i haven't located that source code, that uses a method similar to svelte-docs for processing markdown.
...the example-viewer can only show examples from a source that is in an angular namespace @angular/component-examples
that makes it possible to define an example to display based on a predefined string key. the inline usage in a markdown file looks like:
<!-- example(cdk-drag-drop-overview) -->
...the svelte markdown preprocessor that is a part of the svelte-docs project is a small amount of code.
...the react project couples the style. it is the only project whose props allow for style to be passed in using a className
prop. as well, it shares with the angular example-viewer an expandable/collapsible prop.
Ideally the system should use the variable version.
Current:
### Add Theme and Core CSS
<link rel="stylesheet" href="https://unpkg.com/union-design-system/dist/theme.css"/>
<link rel="stylesheet" href="https://unpkg.com/union-design-system/dist/union.css"/>
I'm putting this into a sapper project, guessing that "template.html" is the way to do it.
I could use guidance on the place to put these files.
error:
<Navigation> is not a valid SSR component. You may need to review your build config to ensure that dependencies are compiled, rather than imported as pre-compiled modules
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.