create-svelte-library-template 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/index.js +0 -0
- package/package.json +4 -3
- package/template/.storybook/main.ts +14 -0
- package/template/.storybook/preview.ts +21 -0
- package/template/_gitignore +1 -2
- package/template/.svelte-kit/__package__/components/button.svelte +0 -4
- package/template/.svelte-kit/__package__/components/button.svelte.d.ts +0 -18
- package/template/.svelte-kit/__package__/index.d.ts +0 -1
- package/template/.svelte-kit/__package__/index.js +0 -2
- package/template/dist/components/button.svelte +0 -4
- package/template/dist/components/button.svelte.d.ts +0 -18
- package/template/dist/index.d.ts +0 -1
- package/template/dist/index.js +0 -2
package/bin/index.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-svelte-library-template",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2",
|
|
4
4
|
"description": "A CLI to scaffold a pure Svelte component library",
|
|
5
5
|
"bin": {
|
|
6
6
|
"create-svelte-library-template": "./bin/index.js"
|
|
7
7
|
},
|
|
8
8
|
"files": [
|
|
9
9
|
"bin",
|
|
10
|
-
"template"
|
|
10
|
+
"template",
|
|
11
|
+
"!template/.svelte-kit",
|
|
12
|
+
"!template/dist"
|
|
11
13
|
],
|
|
12
14
|
"type": "module"
|
|
13
15
|
}
|
|
14
|
-
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { StorybookConfig } from '@storybook/svelte-vite';
|
|
2
|
+
|
|
3
|
+
const config: StorybookConfig = {
|
|
4
|
+
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|ts|svelte)'],
|
|
5
|
+
addons: [
|
|
6
|
+
'@storybook/addon-svelte-csf',
|
|
7
|
+
'@chromatic-com/storybook',
|
|
8
|
+
'@storybook/addon-vitest',
|
|
9
|
+
'@storybook/addon-a11y',
|
|
10
|
+
'@storybook/addon-docs'
|
|
11
|
+
],
|
|
12
|
+
framework: '@storybook/svelte-vite'
|
|
13
|
+
};
|
|
14
|
+
export default config;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { Preview } from '@storybook/svelte-vite';
|
|
2
|
+
|
|
3
|
+
const preview: Preview = {
|
|
4
|
+
parameters: {
|
|
5
|
+
controls: {
|
|
6
|
+
matchers: {
|
|
7
|
+
color: /(background|color)$/i,
|
|
8
|
+
date: /Date$/i
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
|
|
12
|
+
a11y: {
|
|
13
|
+
// 'todo' - show a11y violations in the test UI only
|
|
14
|
+
// 'error' - fail CI on a11y violations
|
|
15
|
+
// 'off' - skip a11y checks entirely
|
|
16
|
+
test: 'todo'
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export default preview;
|
package/template/_gitignore
CHANGED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
-
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
-
$$bindings?: Bindings;
|
|
4
|
-
} & Exports;
|
|
5
|
-
(internal: unknown, props: {
|
|
6
|
-
$$events?: Events;
|
|
7
|
-
$$slots?: Slots;
|
|
8
|
-
}): Exports & {
|
|
9
|
-
$set?: any;
|
|
10
|
-
$on?: any;
|
|
11
|
-
};
|
|
12
|
-
z_$$bindings?: Bindings;
|
|
13
|
-
}
|
|
14
|
-
declare const Button: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
15
|
-
[evt: string]: CustomEvent<any>;
|
|
16
|
-
}, {}, {}, string>;
|
|
17
|
-
type Button = InstanceType<typeof Button>;
|
|
18
|
-
export default Button;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as Button } from './components/button.svelte';
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
-
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
-
$$bindings?: Bindings;
|
|
4
|
-
} & Exports;
|
|
5
|
-
(internal: unknown, props: {
|
|
6
|
-
$$events?: Events;
|
|
7
|
-
$$slots?: Slots;
|
|
8
|
-
}): Exports & {
|
|
9
|
-
$set?: any;
|
|
10
|
-
$on?: any;
|
|
11
|
-
};
|
|
12
|
-
z_$$bindings?: Bindings;
|
|
13
|
-
}
|
|
14
|
-
declare const Button: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
15
|
-
[evt: string]: CustomEvent<any>;
|
|
16
|
-
}, {}, {}, string>;
|
|
17
|
-
type Button = InstanceType<typeof Button>;
|
|
18
|
-
export default Button;
|
package/template/dist/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as Button } from './components/button.svelte';
|
package/template/dist/index.js
DELETED