Skip to main content
Module

x/valtio/package.json

πŸ’Š Valtio makes proxy-state simple for React and Vanilla
Go to Latest
File
{ "name": "valtio", "private": true, "version": "1.7.6", "description": "πŸ’Š Valtio makes proxy-state simple for React and Vanilla", "main": "./index.js", "types": "./index.d.ts", "typesVersions": { "<4.5": { "esm/*": [ "ts3.4/*" ], "*": [ "ts3.4/*" ] } }, "exports": { "./package.json": "./package.json", ".": { "import": { "types": "./esm/index.d.mts", "default": "./esm/index.mjs" }, "types": "./index.d.ts", "module": "./esm/index.js", "default": "./index.js" }, "./vanilla": { "import": { "types": "./esm/vanilla.d.mts", "default": "./esm/vanilla.mjs" }, "types": "./vanilla.d.ts", "module": "./esm/vanilla.js", "default": "./vanilla.js" }, "./utils": { "import": { "types": "./esm/utils.d.mts", "default": "./esm/utils.mjs" }, "types": "./utils.d.ts", "module": "./esm/utils.js", "default": "./utils.js" }, "./macro": { "import": { "types": "./esm/macro.d.mts", "default": "./esm/macro.mjs" }, "types": "./macro.d.ts", "module": "./esm/macro.js", "default": "./macro.js" }, "./macro/vite": { "import": { "types": "./esm/macro/vite.d.mts", "default": "./esm/macro/vite.mjs" }, "types": "./esm/macro/vite.d.ts", "module": "./esm/macro/vite.js", "default": "./macro/vite.js" } }, "files": [ "**" ], "sideEffects": false, "scripts": { "prebuild": "shx rm -rf dist", "build": "concurrently -m 8 'yarn:build:*'", "build-watch": "concurrently -n watch: 'yarn:build:* --watch'", "build:base": "rollup -c", "build:vanilla": "rollup -c --config-vanilla", "build:utils": "rollup -c --config-utils", "build:macro": "rollup -c --config-macro", "build:macro-vite": "rollup -c --config-macro_vite", "postbuild": "yarn copy && yarn patch-macro-vite && yarn patch-ts3.4 && yarn patch-esm-ts", "prettier": "prettier '*.{js,json,md}' '{src,tests,docs}/**/*.{ts,tsx,md,mdx}' --write", "prettier:ci": "prettier '*.{js,json,md}' '{src,tests,docs}/**/*.{ts,tsx,md,mdx}' --list-different", "eslint": "eslint --fix '*.{js,json}' '{src,tests}/**/*.{ts,tsx}'", "eslint:ci": "eslint '*.{js,json}' '{src,tests}/**/*.{ts,tsx}'", "pretest": "tsc --noEmit", "test": "jest", "test:ci": "jest", "test:dev": "jest --watch --no-coverage", "test:coverage:watch": "jest --watch", "copy": "shx cp -r dist/src/* dist/esm && shx mv dist/src/* dist && shx rm -rf dist/{src,tests} && downlevel-dts dist dist/ts3.4 && shx cp package.json readme.md LICENSE dist && json -I -f dist/package.json -e \"this.private=false; this.devDependencies=undefined; this.optionalDependencies=undefined; this.scripts=undefined; this.prettier=undefined; this.jest=undefined;\"", "patch-macro-vite": "shx cp dist/esm/macro/vite.d.ts dist/macro/ && shx mkdir dist/ts3.4/macro && shx cp dist/ts3.4/esm/macro/vite.d.ts dist/ts3.4/macro/", "patch-ts3.4": "node -e \"require('shelljs').find('dist/ts3.4/**/*.d.ts').forEach(f=>require('fs').appendFileSync(f,'declare type Awaited<T> = T extends Promise<infer V> ? V : T;'))\"; shx sed -i 's/^declare type Snapshot<T> =/declare type Snapshot<T> = T extends AnyFunction ? T : T extends AsRef ? T : T extends Promise<any> ? Awaited<T> : { readonly [K in keyof T]: Snapshot2<T[K]> }; type Snapshot2<T> = T extends AnyFunction ? T : T extends AsRef ? T : T extends Promise<any> ? Awaited<T> : { readonly [K in keyof T]: T[K] };declare type _Snapshot<T> =/' 'dist/ts3.4/**/*.d.ts'", "patch-esm-ts": "node -e \"require('shelljs').find('dist/esm/**/*.d.ts').forEach(f=>require('fs').copyFileSync(f,f.replace(/\\.ts$/,'.mts')))\"; shx sed -i \"s/ from '(\\..*)';$/ from '\\$1.mjs';/\" 'dist/esm/**/*.d.mts'; shx sed -i \"s/^declare module '(\\..*)'/declare module '\\$1.mjs'/\" 'dist/esm/**/*.d.mts'" }, "engines": { "node": ">=12.7.0" }, "prettier": { "semi": false, "trailingComma": "es5", "singleQuote": true, "bracketSameLine": true, "tabWidth": 2, "printWidth": 80 }, "repository": { "type": "git", "url": "git+https://github.com/pmndrs/valtio.git" }, "keywords": [ "react", "state", "manager", "management", "mobx", "proxy", "store" ], "author": "Daishi Kato", "contributors": [], "license": "MIT", "bugs": { "url": "https://github.com/pmndrs/valtio/issues" }, "homepage": "https://github.com/pmndrs/valtio", "jest": { "rootDir": ".", "testEnvironment": "jsdom", "transform": { "^.+\\.(t|j)sx?$": [ "@swc/jest" ] }, "globals": { "__DEV__": true }, "moduleNameMapper": { "^valtio$": "<rootDir>/src/index.ts", "^valtio/(.*)$": "<rootDir>/src/$1.ts", "^proxy-memoize$": "<rootDir>/node_modules/proxy-memoize/dist/wrapper.cjs" }, "modulePathIgnorePatterns": [ "dist" ], "testRegex": "test.(js|ts|tsx)$", "coverageDirectory": "./coverage/", "collectCoverage": true, "coverageReporters": [ "json", "html", "text", "text-summary" ], "collectCoverageFrom": [ "src/**/*.{js,ts,tsx}", "tests/**/*.{js,ts,tsx}" ] }, "dependencies": { "proxy-compare": "2.3.0", "use-sync-external-store": "1.2.0" }, "devDependencies": { "@babel/core": "^7.20.2", "@babel/helper-module-imports": "^7.18.6", "@babel/plugin-transform-react-jsx": "^7.19.0", "@babel/plugin-transform-typescript": "^7.20.2", "@babel/preset-env": "^7.20.2", "@babel/types": "^7.20.2", "@redux-devtools/extension": "^3.2.3", "@rollup/plugin-alias": "^4.0.2", "@rollup/plugin-babel": "^6.0.2", "@rollup/plugin-node-resolve": "^15.0.1", "@rollup/plugin-replace": "^5.0.1", "@rollup/plugin-typescript": "^9.0.2", "@swc/core": "1.3.18", "@swc/jest": "^0.2.23", "@testing-library/react": "^13.4.0", "@types/babel-plugin-macros": "^2.8.5", "@types/jest": "^29.2.3", "@types/react": "^18.0.25", "@types/react-dom": "^18.0.9", "@types/use-sync-external-store": "^0.0.3", "@typescript-eslint/eslint-plugin": "^5.43.0", "@typescript-eslint/parser": "^5.43.0", "aslemammad-vite-plugin-macro": "^1.0.0", "babel-plugin-macros": "^3.1.0", "babel-plugin-tester": "^10.1.0", "concurrently": "^7.5.0", "downlevel-dts": "^0.11.0", "esbuild": "^0.15.14", "eslint": "^8.27.0", "eslint-config-prettier": "^8.5.0", "eslint-import-resolver-alias": "^1.1.2", "eslint-plugin-import": "^2.26.0", "eslint-plugin-jest": "^27.1.5", "eslint-plugin-prettier": "^4.2.1", "eslint-plugin-react": "^7.31.10", "eslint-plugin-react-hooks": "^4.6.0", "jest": "^29.3.1", "jest-environment-jsdom": "^29.3.1", "json": "^11.0.0", "postinstall-postinstall": "^2.1.0", "prettier": "^2.7.1", "proxy-memoize": "^1.2.0", "react": "^18.2.0", "react-dom": "^18.2.0", "redux": "^4.2.0", "rollup": "^3.3.0", "rollup-plugin-esbuild": "^5.0.0", "rollup-plugin-terser": "^7.0.2", "shx": "^0.3.4", "tslib": "^2.4.1", "typescript": "^4.9.3", "vite": "^3.2.4" }, "resolutions": { "date-fns": "2.27.0" }, "peerDependencies": { "@babel/helper-module-imports": ">=7.12", "@babel/types": ">=7.13", "aslemammad-vite-plugin-macro": ">=1.0.0-alpha.1", "babel-plugin-macros": ">=3.0", "react": ">=16.8", "vite": ">=2.8.6" }, "peerDependenciesMeta": { "vite": { "optional": true }, "aslemammad-vite-plugin-macro": { "optional": true }, "@babel/helper-module-imports": { "optional": true }, "@babel/types": { "optional": true }, "babel-plugin-macros": { "optional": true }, "react": { "optional": true } }}