Skip to content
This repository was archived by the owner on Aug 15, 2019. It is now read-only.

Conversation

dsmilkov
Copy link
Contributor

@dsmilkov dsmilkov commented Jun 28, 2019

Adding browser.crypto: false to package.json results in not including crypto and its dependencies when using browserify and parcel as bundlers for an end application.

Test used:
I made a hello-world js application that depends on tfjs-core and build it with parcel.
Expected my bundle to be ~500kb, but I got 810kb. This fixed the issue.


This change is Reviewable

Adding browser.crypto: false to package.json results in not including crypto and it's dependencies when using `browserify` and `parcel` as bundlers for an end application.

Test used:
I made a hello-world js application that depends on tfjs-core.
Expected my bundle to be ~500kb, but I got 810kb. This fixed the issue
@dsmilkov dsmilkov requested review from tafsiri and nsthorat June 28, 2019 20:27
dsmilkov added a commit to tensorflow/tfjs-data that referenced this pull request Jun 28, 2019
Adding `browser.crypto: false` to `package.json` results in not including crypto and it's dependencies when using `browserify` and `parcel` as bundlers for an end application.

Test used:
I made a hello-world js application that depends on tfjs-core and tfjs-data.
Expected my bundle to be ~550kb, but I got 860kb. This fixed the issue.

Analogous PR in tfjs-core: tensorflow/tfjs-core#1821
Copy link
Contributor

@tafsiri tafsiri left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r1.
Reviewable status: :shipit: complete! 1 of 1 approvals obtained (waiting on @nsthorat and @tafsiri)

dsmilkov added a commit to tensorflow/tfjs-data that referenced this pull request Jun 28, 2019
Adding `browser.crypto: false` to `package.json` results in not including crypto and it's dependencies when using `browserify` and `parcel` as bundlers for an end application.

Test used:
I made a hello-world js application that depends on tfjs-core and tfjs-data.
Expected my bundle to be ~550kb, but I got 860kb. This fixed the issue.

Analogous PR in tfjs-core: tensorflow/tfjs-core#1821
@dsmilkov dsmilkov merged commit 0ed513a into master Jun 28, 2019
@dsmilkov dsmilkov deleted the dsmilkov-patch-1 branch June 28, 2019 20:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants