add metadata and build process
This commit is contained in:
parent
32094e87eb
commit
6333eef901
6
.gitignore
vendored
Normal file
6
.gitignore
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
/dist/
|
||||
/node_modules/
|
||||
/package-lock.json
|
||||
/pnpm-lock.yaml
|
||||
/shrinkwrap.yaml
|
||||
/yarn.lock
|
4
.prettierrc.yaml
Normal file
4
.prettierrc.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
printWidth: 120
|
||||
useTabs: true
|
||||
singleQuote: true
|
||||
trailingComma: all
|
38
package.json
Normal file
38
package.json
Normal file
@ -0,0 +1,38 @@
|
||||
{
|
||||
"name": "@conduitry/autocache",
|
||||
"version": "0.0.0",
|
||||
"description": "A cache that cleans itself",
|
||||
"keywords": [
|
||||
"cache"
|
||||
],
|
||||
"main": "dist/index.cjs.js",
|
||||
"module": "dist/index.esm.js",
|
||||
"types": "types/index.d.ts",
|
||||
"files": [
|
||||
"dist",
|
||||
"types"
|
||||
],
|
||||
"engines": {
|
||||
"node": "^12"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/Conduitry/autocache.git"
|
||||
},
|
||||
"author": "Conduitry",
|
||||
"license": "MIT",
|
||||
"bugs": {
|
||||
"url": "https://github.com/Conduitry/autocache/issues"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "=12",
|
||||
"rollup": "^2",
|
||||
"rollup-plugin-cheap-ts": "Conduitry/rollup-plugin-cheap-ts#semver:^1",
|
||||
"typescript": "^4"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "rollup -c",
|
||||
"dev": "rollup -cw",
|
||||
"prepare": "npm run build"
|
||||
}
|
||||
}
|
11
rollup.config.js
Normal file
11
rollup.config.js
Normal file
@ -0,0 +1,11 @@
|
||||
import cheap_ts from 'rollup-plugin-cheap-ts';
|
||||
|
||||
export default {
|
||||
input: './src/index',
|
||||
external: name => /^[a-z]/.test(name),
|
||||
plugins: [cheap_ts()],
|
||||
output: [
|
||||
{ file: 'dist/index.cjs.js', format: 'cjs', sourcemap: true, interop: false, preferConst: true },
|
||||
{ file: 'dist/index.esm.js', format: 'esm', sourcemap: true, preferConst: true },
|
||||
],
|
||||
};
|
11
tsconfig.json
Normal file
11
tsconfig.json
Normal file
@ -0,0 +1,11 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"noUnusedLocals": true,
|
||||
"removeComments": true,
|
||||
"sourceMap": true,
|
||||
"target": "esnext"
|
||||
},
|
||||
"include": ["src"]
|
||||
}
|
Loading…
Reference in New Issue
Block a user