Socket
Socket
Sign inDemoInstall

storybook-vue-addon

Package Overview
Dependencies
220
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.1 to 0.2.0

dist/chunk-E3I4I7UR.js

2

dist/esbuild.js
import {
src_default
} from "./chunk-OOJYXQL2.js";
} from "./chunk-XGHS4HKD.js";

@@ -5,0 +5,0 @@ // src/esbuild.ts

import {
src_default
} from "./chunk-OOJYXQL2.js";
} from "./chunk-XGHS4HKD.js";
export {
src_default as default
};
import {
src_default
} from "./chunk-OOJYXQL2.js";
} from "./chunk-XGHS4HKD.js";

@@ -5,0 +5,0 @@ // src/nuxt.ts

import {
src_default
} from "./chunk-OOJYXQL2.js";
} from "./chunk-XGHS4HKD.js";

@@ -5,0 +5,0 @@ // src/rollup.ts

import { StorybookViteConfig } from '@storybook/builder-vite';
import { StoryIndexer } from '@storybook/types';
declare const viteFinal: StorybookViteConfig['viteFinal'];
declare const storyIndexers: (indexers: StoryIndexer[]) => StoryIndexer[];
export { viteFinal };
export { storyIndexers, viteFinal };
import {
vite_default
} from "./chunk-K6Q6EFRX.js";
import "./chunk-OOJYXQL2.js";
} from "./chunk-E3I4I7UR.js";
import {
N,
parse
} from "./chunk-XGHS4HKD.js";
// src/core/indexer.ts
import fs from "fs/promises";
async function indexer(fileName, options) {
const code = (await fs.readFile(fileName, { encoding: "utf-8" })).toString();
return indexerCode(code, options);
}
function indexerCode(code, { makeTitle }) {
const { meta, stories } = parse(code);
return {
meta: { title: makeTitle(meta.title) },
stories: stories.map(({ id, title }) => ({
id: N(meta.title || "default", id),
name: title
}))
};
}
// src/storybook.ts

@@ -12,4 +32,14 @@ var viteFinal = (config) => {

};
var storyIndexers = (indexers) => {
return [
{
test: /\.stories\.vue$/,
indexer
},
...indexers || []
];
};
export {
storyIndexers,
viteFinal
};
import {
vite_default
} from "./chunk-K6Q6EFRX.js";
import "./chunk-OOJYXQL2.js";
} from "./chunk-E3I4I7UR.js";
import "./chunk-XGHS4HKD.js";
export {
vite_default as default
};
import {
src_default
} from "./chunk-OOJYXQL2.js";
} from "./chunk-XGHS4HKD.js";

@@ -5,0 +5,0 @@ // src/webpack.ts

{
"name": "storybook-vue-addon",
"type": "module",
"version": "0.1.1",
"packageManager": "pnpm@7.26.3",
"version": "0.2.0",
"packageManager": "pnpm@7.29.3",
"description": "Storybook stories in native Vue format",

@@ -76,31 +76,31 @@ "license": "MIT",

"consola": "^2.15.3",
"prettier": "^2.8.3",
"prettier": "^2.8.4",
"prettier-plugin-organize-imports": "^3.2.2",
"unplugin": "^1.0.1"
"unplugin": "^1.3.1"
},
"peerDependencies": {
"vite": "^4.0.4",
"vue": "^3.2.45"
"vite": "^4.2.0",
"vue": "^3.2.47"
},
"devDependencies": {
"@nuxt/schema": "^3.1.1",
"@nuxt/schema": "^3.3.1",
"@nuxtjs/eslint-config-typescript": "^12.0.0",
"@types/node": "^18.11.18",
"@types/node": "^18.15.3",
"@types/prettier": "^2.7.2",
"@vitest/coverage-c8": "^0.28.3",
"@vitest/coverage-c8": "^0.29.3",
"cross-env": "^7.0.3",
"eslint": "^8.33.0",
"eslint-config-prettier": "^8.6.0",
"eslint": "^8.36.0",
"eslint-config-prettier": "^8.7.0",
"eslint-plugin-unused-imports": "^2.0.0",
"esno": "^0.16.3",
"fast-glob": "^3.2.12",
"nodemon": "^2.0.20",
"rimraf": "^4.1.2",
"rollup": "^3.12.1",
"tsup": "^6.5.0",
"typescript": "^4.9.5",
"vite": "^4.0.4",
"vitest": "^0.28.3",
"vue": "^3.2.45",
"webpack": "^5.75.0"
"nodemon": "^2.0.21",
"rimraf": "^4.4.0",
"rollup": "^3.19.1",
"tsup": "^6.6.3",
"typescript": "^5.0.2",
"vite": "^4.2.0",
"vitest": "^0.29.3",
"vue": "^3.2.47",
"webpack": "^5.76.2"
},

@@ -116,2 +116,3 @@ "scripts": {

"example:vite": "npm -C examples/vite run storybook",
"example:vite:build": "npm -C examples/vite run build-storybook",
"example:vite:app": "npm -C examples/vite run dev",

@@ -118,0 +119,0 @@ "test": "vitest"

@@ -45,2 +45,8 @@ # Storybook Vue Addon

- Write stories as idiomatic Vue templates, bye bye string-based templates, as wished for in [storybookjs/storybook#9768](https://github.com/storybookjs/storybook/issues/9768)
- Syntax highlighting and full editor support (including Volar) for writing story templates
- The component that is displayed needs only be declared once (via `<Stories :component="...">`) and not for every story
- Simple integration with Storybook and automatic Vite support
- Light: Vue stories are transpiled into ordinary CSF stories on the fly with minimal overhead
This package is currently in an early alpha stage and supports only the fundamental Storybook features.

@@ -50,2 +56,4 @@ Compatibility with more advanced features and addons is work in progress.

The way to write stories as idiomatic Vue templates is heavily inspired by the great [Histoire](https://histoire.dev/).
## Installation

@@ -52,0 +60,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with โšก๏ธ by Socket Inc