@modyfi/vite-plugin-yaml
Advanced tools
Comparing version 1.0.1 to 1.0.2
declare module '*.yaml' { | ||
const value: string; | ||
const value: Record<string, any>; | ||
export default value; | ||
} | ||
declare module '*.yml' { | ||
const value: string; | ||
const value: Record<string, any>; | ||
export default value; | ||
} |
{ | ||
"name": "@modyfi/vite-plugin-yaml", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "Import YAML files as JS objects 🔌", | ||
@@ -12,9 +12,5 @@ "type": "module", | ||
"license": "MIT", | ||
"scripts": { | ||
"start": "tsup --watch src", | ||
"build": "tsup" | ||
}, | ||
"exports": { | ||
".": { | ||
"require": "./dist/index.js", | ||
"require": "./dist/index.cjs", | ||
"import": "./dist/index.js" | ||
@@ -28,3 +24,3 @@ }, | ||
"module": "dist/index.js", | ||
"types": "index.d.ts", | ||
"types": "dist/index.d.ts", | ||
"files": [ | ||
@@ -38,4 +34,14 @@ "dist", | ||
"vite-plugin", | ||
"yaml" | ||
"yaml", | ||
"yml", | ||
"modyfi" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/Modyfi/vite-plugin-yaml" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/Modyfi/vite-plugin-yaml/issues" | ||
}, | ||
"homepage": "https://github.com/Modyfi/vite-plugin-yaml/tree/main/#readme", | ||
"peerDependencies": { | ||
@@ -46,10 +52,23 @@ "vite": "^2.6.0" | ||
"@rollup/pluginutils": "^4.1.2", | ||
"js-yaml": "^4.1.0", | ||
"tosource": "^2.0.0-alpha.3" | ||
}, | ||
"devDependencies": { | ||
"@types/js-yaml": "^4.0.5", | ||
"js-yaml": "^4.1.0", | ||
"rollup": "^2.68.0", | ||
"tosource": "^2.0.0-alpha.3", | ||
"c8": "^7.11.0", | ||
"tsup": "^5.11.13", | ||
"typescript": "^4.5.5", | ||
"vite": "2.7.10" | ||
} | ||
} | ||
"vite": "2.7.10", | ||
"vitest": "^0.5.5" | ||
}, | ||
"scripts": { | ||
"dev": "tsup --watch src", | ||
"example:dev": "pnpm -C example run dev", | ||
"example:build": "pnpm run build && npm -C example run build", | ||
"build": "tsup", | ||
"test": "vitest", | ||
"test:watch": "vitest -w", | ||
"coverage": "vitest run --coverage" | ||
}, | ||
"readme": "# 🧹 vite-plugin-yaml\n\nTransforms a YAML file into a JS object.\n\n## 🚀 Install\n\n```\nnpm install -D @modyfi/vite-plugin-yaml\n# or\n# yarn add -D @modyfi/vite-plugin-yaml\n# or\n# pnpm i -D @modyfi/vite-plugin-yaml\n```\n\n## 🦄 Usage\n\nAdd `ViteYAML` to `vite.config.js / vite.config.ts`:\n\n```ts\n// vite.config.js / vite.config.ts\nimport ViteYaml from '@modyfi/vite-plugin-yaml';\n\nexport default {\n plugins: [\n ViteYaml(), // you may configure the plugin by passing in an object with the options listed below\n ],\n};\n```\n\n### 🔦 TypeScript support\n\nThe recommended way to add type definitions for `.yaml` or `.yml` modules is via a `tsconfig.json` file.\n\n```json\n// tsconfig.json\n{\n \"compilerOptions\": {\n ...\n \"types\": [\n ...\n \"@modyfi/vite-plugin-yaml/modules\"\n ],\n }\n}\n```\n\nYou may also add type definitions without `tsconfig`:\n\n```ts\n// vite-env.d.ts\n/// <reference types=\"@modyfi/vite-plugin-yaml/modules\" />\n```\n\n## 🐛 Options\n\n```ts\n/**\n * A minimatch pattern, or array of patterns, which specifies the files in the build the plugin should operate on.\n *\n * By default all files are targeted.\n */\ninclude?: FilterPattern;\n/**\n * A minimatch pattern, or array of patterns, which specifies the files in the build the plugin should ignore.\n *\n * By default no files are ignored.\n */\nexclude?: FilterPattern;\n/**\n * Schema used to parse yaml files.\n *\n * @see https://github.com/nodeca/js-yaml/blob/49baadd52af887d2991e2c39a6639baa56d6c71b/README.md#load-string---options-\n */\nschema?: Schema;\n/**\n * A function that will be called for error reporting.\n *\n * Defaults to `console.warn()`.\n */\nonWarning?: (warning: YAMLException) => void;\n```\n" | ||
} |
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
8383
4
6
96
0
0
0
6
+ Addedrollup@2.77.3(transitive)
+ Addedvite@2.9.18(transitive)
- Removed@types/js-yaml@^4.0.5
- Removedrollup@^2.68.0
- Removedtsup@^5.11.13
- Removedtypescript@^4.5.5
- Removedvite@2.7.10
- Removed@isaacs/cliui@8.0.2(transitive)
- Removed@jridgewell/gen-mapping@0.3.8(transitive)
- Removed@jridgewell/resolve-uri@3.1.2(transitive)
- Removed@jridgewell/set-array@1.2.1(transitive)
- Removed@jridgewell/sourcemap-codec@1.5.0(transitive)
- Removed@jridgewell/trace-mapping@0.3.25(transitive)
- Removed@nodelib/fs.scandir@2.1.5(transitive)
- Removed@nodelib/fs.stat@2.0.5(transitive)
- Removed@nodelib/fs.walk@1.2.8(transitive)
- Removed@pkgjs/parseargs@0.11.0(transitive)
- Removed@types/js-yaml@4.0.9(transitive)
- Removedansi-regex@5.0.16.1.0(transitive)
- Removedansi-styles@4.3.06.2.1(transitive)
- Removedany-promise@1.3.0(transitive)
- Removedanymatch@3.1.3(transitive)
- Removedarray-union@2.1.0(transitive)
- Removedbalanced-match@1.0.2(transitive)
- Removedbinary-extensions@2.3.0(transitive)
- Removedbrace-expansion@2.0.1(transitive)
- Removedbraces@3.0.3(transitive)
- Removedbundle-require@3.1.2(transitive)
- Removedcac@6.7.14(transitive)
- Removedchokidar@3.6.0(transitive)
- Removedcolor-convert@2.0.1(transitive)
- Removedcolor-name@1.1.4(transitive)
- Removedcommander@4.1.1(transitive)
- Removedcross-spawn@7.0.6(transitive)
- Removeddebug@4.4.0(transitive)
- Removeddir-glob@3.0.1(transitive)
- Removedeastasianwidth@0.2.0(transitive)
- Removedemoji-regex@8.0.09.2.2(transitive)
- Removedesbuild@0.13.15(transitive)
- Removedesbuild-android-arm64@0.13.15(transitive)
- Removedesbuild-darwin-64@0.13.15(transitive)
- Removedesbuild-darwin-arm64@0.13.15(transitive)
- Removedesbuild-freebsd-64@0.13.15(transitive)
- Removedesbuild-freebsd-arm64@0.13.15(transitive)
- Removedesbuild-linux-32@0.13.15(transitive)
- Removedesbuild-linux-64@0.13.15(transitive)
- Removedesbuild-linux-arm@0.13.15(transitive)
- Removedesbuild-linux-arm64@0.13.15(transitive)
- Removedesbuild-linux-mips64le@0.13.15(transitive)
- Removedesbuild-linux-ppc64le@0.13.15(transitive)
- Removedesbuild-netbsd-64@0.13.15(transitive)
- Removedesbuild-openbsd-64@0.13.15(transitive)
- Removedesbuild-sunos-64@0.13.15(transitive)
- Removedesbuild-windows-32@0.13.15(transitive)
- Removedesbuild-windows-64@0.13.15(transitive)
- Removedesbuild-windows-arm64@0.13.15(transitive)
- Removedexeca@5.1.1(transitive)
- Removedfast-glob@3.3.3(transitive)
- Removedfastq@1.18.0(transitive)
- Removedfill-range@7.1.1(transitive)
- Removedforeground-child@3.3.0(transitive)
- Removedget-stream@6.0.1(transitive)
- Removedglob@10.4.5(transitive)
- Removedglob-parent@5.1.2(transitive)
- Removedglobby@11.1.0(transitive)
- Removedhuman-signals@2.1.0(transitive)
- Removedignore@5.3.2(transitive)
- Removedis-binary-path@2.1.0(transitive)
- Removedis-extglob@2.1.1(transitive)
- Removedis-fullwidth-code-point@3.0.0(transitive)
- Removedis-glob@4.0.3(transitive)
- Removedis-number@7.0.0(transitive)
- Removedis-stream@2.0.1(transitive)
- Removedisexe@2.0.0(transitive)
- Removedjackspeak@3.4.3(transitive)
- Removedjoycon@3.1.1(transitive)
- Removedlilconfig@2.1.0(transitive)
- Removedlines-and-columns@1.2.4(transitive)
- Removedload-tsconfig@0.2.5(transitive)
- Removedlodash.sortby@4.7.0(transitive)
- Removedlru-cache@10.4.3(transitive)
- Removedmerge-stream@2.0.0(transitive)
- Removedmerge2@1.4.1(transitive)
- Removedmicromatch@4.0.8(transitive)
- Removedmimic-fn@2.1.0(transitive)
- Removedminimatch@9.0.5(transitive)
- Removedminipass@7.1.2(transitive)
- Removedms@2.1.3(transitive)
- Removedmz@2.7.0(transitive)
- Removednormalize-path@3.0.0(transitive)
- Removednpm-run-path@4.0.1(transitive)
- Removedobject-assign@4.1.1(transitive)
- Removedonetime@5.1.2(transitive)
- Removedpackage-json-from-dist@1.0.1(transitive)
- Removedpath-key@3.1.1(transitive)
- Removedpath-scurry@1.11.1(transitive)
- Removedpath-type@4.0.0(transitive)
- Removedpirates@4.0.6(transitive)
- Removedpostcss-load-config@3.1.4(transitive)
- Removedpunycode@2.3.1(transitive)
- Removedqueue-microtask@1.2.3(transitive)
- Removedreaddirp@3.6.0(transitive)
- Removedresolve-from@5.0.0(transitive)
- Removedreusify@1.0.4(transitive)
- Removedrollup@2.79.2(transitive)
- Removedrun-parallel@1.2.0(transitive)
- Removedshebang-command@2.0.0(transitive)
- Removedshebang-regex@3.0.0(transitive)
- Removedsignal-exit@3.0.74.1.0(transitive)
- Removedslash@3.0.0(transitive)
- Removedsource-map@0.8.0-beta.0(transitive)
- Removedstring-width@4.2.35.1.2(transitive)
- Removedstrip-ansi@6.0.17.1.0(transitive)
- Removedstrip-final-newline@2.0.0(transitive)
- Removedsucrase@3.35.0(transitive)
- Removedthenify@3.3.1(transitive)
- Removedthenify-all@1.6.0(transitive)
- Removedto-regex-range@5.0.1(transitive)
- Removedtr46@1.0.1(transitive)
- Removedtree-kill@1.2.2(transitive)
- Removedts-interface-checker@0.1.13(transitive)
- Removedtsup@5.12.9(transitive)
- Removedtypescript@4.9.5(transitive)
- Removedvite@2.7.10(transitive)
- Removedwebidl-conversions@4.0.2(transitive)
- Removedwhatwg-url@7.1.0(transitive)
- Removedwhich@2.0.2(transitive)
- Removedwrap-ansi@7.0.08.1.0(transitive)
- Removedyaml@1.10.2(transitive)