Skip to content

Commit

Permalink
fix: use browser field in package.json if it exists (#129)
Browse files Browse the repository at this point in the history
  • Loading branch information
amcgee authored and varl committed Oct 21, 2019
1 parent d692e0b commit 33742cc
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 5 deletions.
2 changes: 1 addition & 1 deletion cli/config/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ const bundle = ({
* fore-knowledge of all the libraries an app/lib could depend on.
* See https://github.com/rollup/rollup-plugin-commonjs/issues/211#issuecomment-337897124
*/
mainFields: ['main'],
mainFields: ['browser', 'main'],
}),
commonjs({ include: /node_modules/ }),
visualize({
Expand Down
18 changes: 16 additions & 2 deletions examples/simple-app/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -927,7 +927,7 @@
integrity sha512-rt2PZYZHwOq7qkkyczLYBgfReaENwauxx8iaTimTwdJrAXRUPkbhjlor63/00XgAY95tsZL7nMK7x3TwiSUfpQ==

"@dhis2/cli-app-scripts@file:../../cli":
version "1.5.3"
version "1.5.4"
dependencies:
"@babel/core" "^7.6.2"
"@babel/plugin-proposal-class-properties" "^7.4.4"
Expand All @@ -943,6 +943,7 @@
babel-jest "^24.9.0"
chalk "^2.4.2"
classnames "^2.2.6"
detect-port "^1.3.0"
dotenv "^8.1.0"
dotenv-expand "^5.1.0"
fs-extra "^8.1.0"
Expand Down Expand Up @@ -1365,6 +1366,11 @@ acorn@^7.0.0:
resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.0.0.tgz#26b8d1cd9a9b700350b71c0905546f64d1284e7a"
integrity sha512-PaF/MduxijYYt7unVGRuds1vBC9bFxbNf+VWqhOClfdgy7RlVkQqt610ig1/yxTgsDIfW1cWDel5EBbOy3jdtQ==

address@^1.0.1:
version "1.1.2"
resolved "https://registry.yarnpkg.com/address/-/address-1.1.2.tgz#bf1116c9c758c51b7a933d296b72c221ed9428b6"
integrity sha512-aT6camzM4xEA54YVJYSqxz1kv4IHnQZRtThJJHhUMRExaU5spC7jX5ugSwTaTgJliIgs4VhZOk7htClvQ/LmRA==

ajv@^6.5.5:
version "6.10.0"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.0.tgz#90d0d54439da587cd7e843bfb7045f50bd22bdf1"
Expand Down Expand Up @@ -2389,7 +2395,7 @@ [email protected]:
dependencies:
ms "2.0.0"

debug@^2.2.0, debug@^2.3.3:
debug@^2.2.0, debug@^2.3.3, debug@^2.6.0:
version "2.6.9"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f"
integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==
Expand Down Expand Up @@ -2496,6 +2502,14 @@ detect-newline@^2.1.0:
resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2"
integrity sha1-9B8cEL5LAOh7XxPaaAdZ8sW/0+I=

detect-port@^1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/detect-port/-/detect-port-1.3.0.tgz#d9c40e9accadd4df5cac6a782aefd014d573d1f1"
integrity sha512-E+B1gzkl2gqxt1IhUzwjrxBKRqx1UzC3WLONHinn8S3T6lwV/agVCyitiFOsGJ/eYuEUBvD71MZHy3Pv1G9doQ==
dependencies:
address "^1.0.1"
debug "^2.6.0"

diff-sequences@^24.9.0:
version "24.9.0"
resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-24.9.0.tgz#5715d6244e2aa65f48bba0bc972db0b0b11e95b5"
Expand Down
18 changes: 16 additions & 2 deletions shell/adapter/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -863,7 +863,7 @@
integrity sha512-rt2PZYZHwOq7qkkyczLYBgfReaENwauxx8iaTimTwdJrAXRUPkbhjlor63/00XgAY95tsZL7nMK7x3TwiSUfpQ==

"@dhis2/cli-app-scripts@file:../../cli":
version "1.5.3"
version "1.5.4"
dependencies:
"@babel/core" "^7.6.2"
"@babel/plugin-proposal-class-properties" "^7.4.4"
Expand All @@ -879,6 +879,7 @@
babel-jest "^24.9.0"
chalk "^2.4.2"
classnames "^2.2.6"
detect-port "^1.3.0"
dotenv "^8.1.0"
dotenv-expand "^5.1.0"
fs-extra "^8.1.0"
Expand Down Expand Up @@ -1319,6 +1320,11 @@ acorn@^7.0.0:
resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.0.0.tgz#26b8d1cd9a9b700350b71c0905546f64d1284e7a"
integrity sha512-PaF/MduxijYYt7unVGRuds1vBC9bFxbNf+VWqhOClfdgy7RlVkQqt610ig1/yxTgsDIfW1cWDel5EBbOy3jdtQ==

address@^1.0.1:
version "1.1.2"
resolved "https://registry.yarnpkg.com/address/-/address-1.1.2.tgz#bf1116c9c758c51b7a933d296b72c221ed9428b6"
integrity sha512-aT6camzM4xEA54YVJYSqxz1kv4IHnQZRtThJJHhUMRExaU5spC7jX5ugSwTaTgJliIgs4VhZOk7htClvQ/LmRA==

ajv@^6.5.5:
version "6.10.2"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.2.tgz#d3cea04d6b017b2894ad69040fec8b623eb4bd52"
Expand Down Expand Up @@ -2338,7 +2344,7 @@ [email protected]:
dependencies:
ms "2.0.0"

debug@^2.2.0, debug@^2.3.3:
debug@^2.2.0, debug@^2.3.3, debug@^2.6.0:
version "2.6.9"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f"
integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==
Expand Down Expand Up @@ -2445,6 +2451,14 @@ detect-newline@^2.1.0:
resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2"
integrity sha1-9B8cEL5LAOh7XxPaaAdZ8sW/0+I=

detect-port@^1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/detect-port/-/detect-port-1.3.0.tgz#d9c40e9accadd4df5cac6a782aefd014d573d1f1"
integrity sha512-E+B1gzkl2gqxt1IhUzwjrxBKRqx1UzC3WLONHinn8S3T6lwV/agVCyitiFOsGJ/eYuEUBvD71MZHy3Pv1G9doQ==
dependencies:
address "^1.0.1"
debug "^2.6.0"

diff-sequences@^24.9.0:
version "24.9.0"
resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-24.9.0.tgz#5715d6244e2aa65f48bba0bc972db0b0b11e95b5"
Expand Down

0 comments on commit 33742cc

Please sign in to comment.