Skip to content
This repository has been archived by the owner on Mar 4, 2021. It is now read-only.

Commit

Permalink
Explicit global definition
Browse files Browse the repository at this point in the history
Some script bundlers such as Browserify compile a wrapper function over the modules. If var-statement is used to define the global it will be hidden inside it. Use window-global to define Chart global explicitly.
  • Loading branch information
esamattis committed Apr 13, 2013
1 parent 4a94b44 commit 624fbfd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Chart.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
*/

//Define the global Chart Variable as a class.
var Chart = function(context){
window.Chart = function(context){

var chart = this;

Expand Down

0 comments on commit 624fbfd

Please sign in to comment.