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

build/esm-package: update media-chrome to use type:module. Update CJS… #90

Merged
merged 1 commit into from
Nov 8, 2021
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
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,16 @@
"version": "0.3.2",
"description": "Custom elements (web components) for making audio and video player controls that look great in your website or app.",
"main": "dist/index.js",
"type": "module",
"files": [
"dist/*",
"README.md",
"examples/*"
],
"scripts": {
"clean": "rimraf dist",
"build": "snowpack build --config snowpack.prod.config.js",
"dev": "snowpack dev --config snowpack.dev.config.js",
"build": "snowpack build --config snowpack.prod.config.cjs",
"dev": "snowpack dev --config snowpack.dev.config.cjs",
"start": "yarn dev",
"test": "web-test-runner --coverage",
"publish-patch": "yarn run build && np patch --no-tests --any-branch"
Expand Down
File renamed without changes.
20 changes: 20 additions & 0 deletions snowpack.config.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// Snowpack Configuration File
// See all supported options: https://www.snowpack.dev/reference/configuration

/** @type {import("snowpack").SnowpackUserConfig } */
module.exports = {
extends: './snowpack.dev.config.cjs',
mount: {
'__tests__/setup': { url: '/dist/test-setup' },
},
packageOptions: {
/* ... */
polyfillNode: true,
},
testOptions: {
files: ['__tests__/@(unit|integration)/**/*.@(test|spec).js', '__tests__/setup/**/*'],
},
alias: {
'graceful-fs': 'memfs',
},
};
2 changes: 1 addition & 1 deletion snowpack.dev.config.js → snowpack.dev.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

/** @type {import("snowpack").SnowpackUserConfig } */
module.exports = {
extends: './snowpack.common.config.js',
extends: './snowpack.common.config.cjs',
mount: {
'src/js': { url: '/dist' },
// Mount "public" to the root URL path ("/*") and serve files with zero transformations:
Expand Down
2 changes: 1 addition & 1 deletion snowpack.prod.config.js → snowpack.prod.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

/** @type {import("snowpack").SnowpackUserConfig } */
module.exports = {
extends: './snowpack.common.config.js',
extends: './snowpack.common.config.cjs',
mount: {
'src/js': { url: '/' },
},
Expand Down