Skip to content

Commit

Permalink
add package-check lint pass (#1376)
Browse files Browse the repository at this point in the history
  • Loading branch information
FredKSchott authored Oct 21, 2020
1 parent fcfa83f commit c5ee602
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 5 deletions.
17 changes: 16 additions & 1 deletion esinstall/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,17 @@
"version": "0.3.4",
"description": "Convert packages to ESM.",
"license": "MIT",
"keywords": [
"install",
"web",
"dependencies",
"npm",
"esm",
"common.js",
"rollup",
"esbuild",
"cjs"
],
"homepage": "https://github.com/snowpackjs/snowpack/tree/master/esinstall#readme",
"repository": {
"type": "git",
Expand All @@ -15,14 +26,15 @@
"scripts": {
"build": "tsc",
"build:watch": "tsc --watch",
"lint": "tsc --noEmit --noUnusedLocals true --noUnusedParameters true"
"lint": "tsc --noEmit --noUnusedLocals true --noUnusedParameters true && package-check"
},
"types": "lib/index.d.ts",
"main": "lib/index.js",
"exports": {
"import": "./index.esm.mjs",
"require": "./lib/index.js"
},
"files": ["lib"],
"dependencies": {
"@rollup/plugin-alias": "^3.0.1",
"@rollup/plugin-commonjs": "^15.0.0",
Expand All @@ -39,5 +51,8 @@
"rollup": "^2.23.0",
"rollup-plugin-node-polyfills": "^0.2.1",
"validate-npm-package-name": "^3.0.0"
},
"devDependencies": {
"@skypack/package-check": "^0.1.0"
}
}
5 changes: 5 additions & 0 deletions snowpack/index.esm.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import Pkg from './lib/index.js';

export const startDevServer = Pkg.startDevServer;
export const loadAndValidateConfig = Pkg.loadAndValidateConfig;
export const getUrlForFile = Pkg.getUrlForFile;
21 changes: 19 additions & 2 deletions snowpack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@
"description": "The ESM-powered frontend build tool. Fast, lightweight, unbundled.",
"author": "Fred K. Schott <[email protected]>",
"license": "MIT",
"keywords": [
"bundle",
"build",
"build tool",
"web",
"esm",
"esbuild",
"wasm"
],
"repository": {
"type": "git",
"url": "https://github.com/snowpackjs/snowpack.git"
Expand All @@ -14,17 +23,22 @@
"scripts": {
"build": "tsc",
"build:watch": "tsc --watch",
"lint": "tsc --noEmit --noUnusedLocals true --noUnusedParameters true"
"lint": "tsc --noEmit --noUnusedLocals true --noUnusedParameters true && package-check"
},
"engines": {
"node": ">=10.19.0"
},
"main": "lib/index.js",
"types": "lib/index.d.ts",
"main": "lib/index.js",
"exports": {
"import": "./index.esm.mjs",
"require": "./lib/index.js"
},
"bin": {
"sp": "index.bin.js",
"snowpack": "index.bin.js"
},
"files": ["assets", "lib"],
"dependencies": {
"@snowpack/plugin-build-script": "^2.0.11",
"@snowpack/plugin-run-script": "^2.1.7",
Expand Down Expand Up @@ -63,5 +77,8 @@
"validate-npm-package-name": "^3.0.0",
"ws": "^7.3.0",
"yargs-parser": "^18.1.3"
},
"devDependencies": {
"@skypack/package-check": "^0.1.0"
}
}
2 changes: 1 addition & 1 deletion snowpack/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {CLIFlags} from './types/snowpack';
import {clearCache, readLockfile} from './util.js';
export * from './types/snowpack';

// Stable API:
// Stable API (remember to include all in "./index.esm.js" wrapper)
export {startDevServer} from './commands/dev';
export {loadAndValidateConfig};
export {getUrlForFile} from './build/file-urls';
Expand Down
9 changes: 8 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2514,6 +2514,13 @@
dependencies:
"@sinonjs/commons" "^1.7.0"

"@skypack/package-check@^0.1.0":
version "0.1.0"
resolved "https://registry.yarnpkg.com/@skypack/package-check/-/package-check-0.1.0.tgz#aa7aa70e3415ac8da3fbd8f69d6d38073679af41"
integrity sha512-MouyPN2ewOADpBw01HWi6+bo0PmrTPCttyCUBFkT5UAHgQFjJ0AFIVYa4O3cVZCmGkrtA7YksJ7dOG9U9Hz3xA==
dependencies:
kleur "^4.1.3"

"@szmarczak/http-timer@^4.0.5":
version "4.0.5"
resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-4.0.5.tgz#bfbd50211e9dfa51ba07da58a14cdfd333205152"
Expand Down Expand Up @@ -9368,7 +9375,7 @@ kleur@^3.0.3:
resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e"
integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==

kleur@^4.1.1:
kleur@^4.1.1, kleur@^4.1.3:
version "4.1.3"
resolved "https://registry.yarnpkg.com/kleur/-/kleur-4.1.3.tgz#8d262a56d79a137ee1b706e967c0b08a7fef4f4c"
integrity sha512-H1tr8QP2PxFTNwAFM74Mui2b6ovcY9FoxJefgrwxY+OCJcq01k5nvhf4M/KnizzrJvLRap5STUy7dgDV35iUBw==
Expand Down

1 comment on commit c5ee602

@vercel
Copy link

@vercel vercel bot commented on c5ee602 Oct 21, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.