Comments (8)
plotly.js is a heavy user of browserify transforms, not just glslify. Adapting the build tasks to other build systems won't be easy.
May I ask, in what context are you trying to build plotly.js?
If you can't make the switch to browserify, maybe you should consider including plotly.js in a separate <script>
tag than the rest of your code. Note that plotly.js exports the global Plotly
.
I hope this helps.
from plotly.js.
I'm using webpack, since I have a lot of other things (e.g. loaders for babel, Elm, SASS) that I use with it and make a lot of use of the features there. Besides existing webpack loader work, there's some personal preference and other reasons why I don't want to use browserify.
I also ran into a problem with trying to just bundle the dist
build and conflicts with the global Plotly
. It'd be nicer if we just had a UMD build or something, I think, but it's not a huge priority for me.
from plotly.js.
@justinwoo See #14, dist/plotly.js
is UMD but broken ATM. Removing the last line allowed me to use the bundle with JSPM/SystemJS. Might also work for webpack.
from plotly.js.
@Hypercubed, ya, as far as i can tell that last line (dist/plotly.js:83327) is the only thing that limits use with requirejs. with a shim, i get what appears to be a good plotly object. i get the nasty error though.
from plotly.js.
I'd also kindly suggest that d3 be removed from the bundle. I believe many of use will already have a copy of d3 installed, an additional copy in the bundle is redundant. Of course documentation would need to be clear that d3 should be added as a peer.
from plotly.js.
I'd also kindly suggest that d3 be removed from the bundle
This will not happen I'm afraid.
We chose to have an all-in-one bundle for simplicity and robustness (as d3 in notoriously bad at following semver).
Note that d3
is exported onto the Plotly
object. I'd would recommend removing your <script src="d3">
tag and using Plotly.d3
instead d3
(or equivalently mapping window.d3 = Plotly.d3
after importing plotly.js).
from plotly.js.
Fixed in v1.1.0
See webpack example: https://gist.github.com/etpinard/f3d44dab330785368534
from plotly.js.
A webpack
field has been added to the package.json so that you can use plotly.js with webpack as normal. You will see a warning when webpack builds your bundle because it is using the distribution version of plotly.js, but this is unavoidable at the moment.
from plotly.js.
Related Issues (20)
- Pie chart not displaying when plotting big and small numbers at the same time. HOT 2
- how to download the plot in pdf format in chrome browser using plotly.js HOT 2
- The violin plot very weird HOT 1
- Feature: Country colour coding according to filter HOT 2
- Image Trace Not Displayed HOT 3
- The picture showing uncompletely and showing negative data plot HOT 4
- hoverlabel.grouptitlefont getting reset
- Scrollbar sensitivity in plot legend skips legend items
- Latex doesn't render in slider names or step labels.
- Browser Warning due to missing `willReadFrequently` on heatmap HOT 1
- `supply defaults by pass` bug caused by partial range
- Contour Graph does not include Boundary Values
- `stamen` map tiles changes in November 2023 HOT 1
- Bug: X-coordinates are duplicated in plotly_click points
- Changing x axis tick mark labels to a larger font fails to change the font size HOT 1
- changing Layout.xaxis.tickfont.size and Layout.yaxis.tickfont.size fails to work to make the axis tick labels a bigger font. HOT 4
- Overlap of rangeslider and legend
- Timestamp '1970/01/01 00:00:00' formats as 'undefined' in hovertext HOT 2
- Legend properties on shapes property of layouts is not being tracked by Typescript
- Allow `hovertemplate` to accept a closure HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from plotly.js.