-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(build): migrate build system from rollup and parcel to vite
Replaces Rollup and Parcel with Vite as the sole build tool in order to reduce complexity. The changes involve: - Removed `.parcelrc` and `rollup.config.js`, as their functionalities are now handled by Vite. - Introduced multiple Vite config to support the various build outputs previously managed by Rollup. - Updated `package.json` to integrate Vite dependencies and remove those related to Rollup and Parcel (2 Rollup plugins have been retained, including Babel to enhance browser compatibility and Terser for minifying the UMD build). - Modified `scss/pillarbox.scss` to enhance compatibility with the new Vite build setup. This update includes simplifying SCSS imports, making it easier to resolve external dependencies without depending on the file's location. - The server previously started by Parcel for the demo pages is now efficiently handled by Vite's native development server.
- Loading branch information
Showing
15 changed files
with
9,024 additions
and
14,368 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { defineConfig } from 'vite'; | ||
import babel from '@rollup/plugin-babel'; | ||
|
||
export default defineConfig({ | ||
esbuild: false, | ||
build: { | ||
sourcemap: true, | ||
emptyOutDir: false, | ||
lib: { | ||
formats: ['cjs'], | ||
name: 'pillarbox', | ||
entry: './build.umd.js' | ||
}, | ||
rollupOptions: { | ||
external: ['video.js', 'videojs-contrib-eme'], | ||
output: { | ||
entryFileNames: 'pillarbox.cjs.js' | ||
}, | ||
plugins: [babel({ | ||
babelHelpers: 'bundled', | ||
exclude: 'node_modules/**' | ||
})] | ||
} | ||
} | ||
}); |
Oops, something went wrong.