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

Importing into angular app #23

Open
mbeckenbach opened this issue Feb 6, 2020 · 0 comments
Open

Importing into angular app #23

mbeckenbach opened this issue Feb 6, 2020 · 0 comments

Comments

@mbeckenbach
Copy link

Hi,

i tried to import your plugin to an angular app that is using ng-chartist.
https://www.npmjs.com/package/ng-chartist

In order to make this work, the lines 1 to 16 have to be changed, Not sure if this would break someone. Maybe you can review it and add it to the package if possible?

(function (root, factory) {
if (root === undefined && window !== undefined) root = window;
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module unless amdModuleId is set
define(["chartist"], function (a0) {
return (root['Chartist.plugins.ctThreshold'] = factory(a0));
});
} else if (typeof module === 'object' && module.exports) {
// Node. Does not work with strict CommonJS, but
// only CommonJS-like environments that support module.exports,
// like Node.
module.exports = factory(require("chartist"));
} else {
root['Chartist.plugins.ctThreshold'] = factory(root["Chartist"]);
}
}(this, function (Chartist) {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant