Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/594 exports #604

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,14 @@
],
"scripts": {
"install": "cd src/danfojs-base && yarn && cd ../danfojs-browser && yarn && cd ../danfojs-node && yarn",
"build": "cd src/danfojs-node && yarn build:clean && cd ../danfojs-browser && yarn build:clean",
"test": "cd src/danfojs-base && yarn && cd ../danfojs-node && yarn && yarn test:clean && cd ../danfojs-browser && yarn && yarn test:clean"
"build": "yarn build:browser && yarn build:node",
Copy link
Author

Choose a reason for hiding this comment

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

This comes from my other PR #603 so I could run build and tests independently from the root of the project

"build:browser": "cd src/danfojs-browser && yarn build:clean",
"build:node": "cd src/danfojs-node && yarn build:clean",
"pretest": "cd src/danfojs-base && yarn",
"test": "yarn test:browser && yarn test:node",
"pretest:browser": "yarn pretest",
"test:browser": "cd src/danfojs-browser && yarn && yarn test:clean",
"pretest:node": "yarn pretest",
"test:node": "cd src/danfojs-node && yarn && yarn test:clean"
}
}
10 changes: 7 additions & 3 deletions src/danfojs-browser/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,13 @@
"name": "danfojs",
"version": "1.1.2",
"description": "JavaScript library providing high performance, intuitive, and easy to use data structures for manipulating and processing structured data.",
"main": "dist/danfojs-browser/src/index.js",
"types": "dist/danfojs-browser/src/index.d.ts",
"module": "lib/bundle-esm.js",
"exports": {
".": {
"types": "./dist/danfojs-browser/src/index.d.ts",
Copy link
Author

Choose a reason for hiding this comment

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

I'm really unsure about the correct syntax here.

"node": "./dist/danfojs-browser/src/index.js",
"default": "./lib/bundle.esm.js"
}
},
"directories": {
"test": "tests"
},
Expand Down
2 changes: 1 addition & 1 deletion src/danfojs-browser/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const createConfig = () => {
target: "web",
output: {
path: path.resolve(__dirname, "lib"),
filename: "bundle-esm.js",
filename: "bundle.js",
library: "dfd"
},
module: {
Expand Down
Loading