Skip to content
Merged
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@brightsoftware/table",
"version": "0.1.1",
"version": "0.1.2",
"description": "A React table library by bright office system.",
"license": "MIT",
"author": {
Expand Down
10 changes: 3 additions & 7 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,8 @@ const prependUseClient = () => {
};
};

// Read package.json to get all dependencies
const packageJson = JSON.parse(readFileSync('./package.json', 'utf8'));
const external = [
...Object.keys(packageJson.dependencies || {}),
...Object.keys(packageJson.peerDependencies || {}),
];
// TODO: Some how mark all the dependencies as external to make the bundle smaller
// and make sure they get auto installed with all the package managers

// NOTE: due to some reason vite is not adding the import statement for transpiled css file
// that is why this function(plugin) exists.
Expand Down Expand Up @@ -80,7 +76,7 @@ export default defineConfig({
},

rollupOptions: {
external: external,
external: ["react", "react-dom"],
output: {
preserveModules: true,
entryFileNames: '[name].js',
Expand Down