From 1458be2705a6eadf2cdc32d022c38857d5d9d2bc Mon Sep 17 00:00:00 2001 From: Gildas Garcia <1122076+djhi@users.noreply.github.com> Date: Mon, 2 Aug 2021 11:12:02 +0200 Subject: [PATCH] Add build --- package.json | 78 ++++++++++++++++++++++++++++++---------------------- src/index.ts | 1 + 2 files changed, 46 insertions(+), 33 deletions(-) create mode 100644 src/index.ts diff --git a/package.json b/package.json index a6869aa..5c831d3 100644 --- a/package.json +++ b/package.json @@ -1,35 +1,47 @@ { - "name": "ra-supabase", - "version": "1.0.0", - "main": "index.js", - "repository": "git@github.com:marmelab/ra-supabase.git", - "author": "Gildas Garcia <1122076+djhi@users.noreply.github.com>", - "license": "MIT", - "dependencies": { - "@supabase/supabase-js": "^1.21.0", - "ra-core": "^3.17.0" - }, - "devDependencies": { - "@typescript-eslint/eslint-plugin": "^4.28.5", - "@typescript-eslint/parser": "^4.28.5", - "eslint": "^7.7.0", - "eslint-config-prettier": "^6.11.0", - "eslint-config-react-app": "^5.2.1", - "eslint-plugin-cypress": "^2.11.1", - "eslint-plugin-flowtype": "^5.2.0", - "eslint-plugin-import": "^2.22.0", - "eslint-plugin-jsx-a11y": "^6.3.1", - "eslint-plugin-prettier": "^3.1.4", - "eslint-plugin-react": "^7.20.6", - "eslint-plugin-react-hooks": "^4.1.0", - "husky": "^2.3.0", - "jest": "26.6.0", - "prettier": "~2.1.1", - "typescript": "^4.3.4" - }, - "scripts": { - "build": "", - "test": "", - "lint": "eslint --fix ./src" - } + "name": "ra-supabase", + "version": "1.0.0", + "repository": "git@github.com:marmelab/ra-supabase.git", + "author": "Gildas Garcia <1122076+djhi@users.noreply.github.com>", + "license": "MIT", + "files": [ + "*.md", + "lib", + "esm", + "src" + ], + "main": "lib/index", + "module": "esm/index.js", + "types": "esm/index.d.ts", + "sideEffects": false, + "dependencies": { + "@supabase/supabase-js": "^1.21.0", + "ra-core": "^3.17.0" + }, + "devDependencies": { + "@typescript-eslint/eslint-plugin": "^4.28.5", + "@typescript-eslint/parser": "^4.28.5", + "eslint": "^7.7.0", + "eslint-config-prettier": "^6.11.0", + "eslint-config-react-app": "^5.2.1", + "eslint-plugin-cypress": "^2.11.1", + "eslint-plugin-flowtype": "^5.2.0", + "eslint-plugin-import": "^2.22.0", + "eslint-plugin-jsx-a11y": "^6.3.1", + "eslint-plugin-prettier": "^3.1.4", + "eslint-plugin-react": "^7.20.6", + "eslint-plugin-react-hooks": "^4.1.0", + "husky": "^2.3.0", + "jest": "26.6.0", + "prettier": "~2.1.1", + "rimraf": "^3.0.2", + "typescript": "^4.3.4" + }, + "scripts": { + "build": "yarn run build-cjs && yarn run build-esm", + "build-cjs": "rimraf ./lib && tsc", + "build-esm": "rimraf ./esm && tsc --outDir esm --module es2015", + "watch": "tsc --outDir esm --module es2015 --watch", + "lint": "eslint --fix ./src" + } } diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 0000000..c713744 --- /dev/null +++ b/src/index.ts @@ -0,0 +1 @@ +export * from './dataProvider';