Giter VIP home page Giter VIP logo

Comments (3)

bre1470 avatar bre1470 commented on June 20, 2024 1

@jon-a-nygaard Can you check, if some of the open issue points can be marked solved? I believe remove new tags from bundle result was for example done.

from highcharts-assembler.

jon-a-nygaard avatar jon-a-nygaard commented on June 20, 2024

Updates to the AMD pattern

As of v1.3.1 the bundler supports adding module name and dependencies to the AMD define.

Module name

The module name can be set as in the userOptions as following:

build({
  moduleName: 'module-name'
})

If it is not provided in the userOptions the assembler will use the @module tag if found in the entry file.

/**
 * My module
 * @module module-name
 */

Module dependencies

The module dependencies can be set in the userOptions as following:

build({
  requires: ['highcharts', 'highcharts/modules/exporting']
})

If it is not provided in the userOptions the assembler will use the @requires tags if found in the entry file.

/**
 * This module has a dependency on `highcharts` and `highcharts/modules/exporting`
 * @requires highcharts
 * @requires highcharts/modules/exporting
 */

If dependencies are provided, the assembler will assume that the first dependency is the Highcharts instance. It will then run the factory function on the instance, and afterwards attach the updated instance to the returned factory function as a property named Highcharts.

define(..., function (Highcharts) {
  factory(Highcharts);
  factory.Highcharts = Highcharts;
  return factory;
});

from highcharts-assembler.

jon-a-nygaard avatar jon-a-nygaard commented on June 20, 2024

@bre1470 Yes, I believe the criteria in this issue is met and that we can close the issue.

from highcharts-assembler.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.