Comments (1)
@CodeRedPaul in this commit fbb7ac9 I'm adding a support of AMD export with yarn build
and yarn dev-amd
. An example of how to use the exported files with requirejs could be seen here https://github.com/krasimir/webpack-library-starter/blob/master/lib/requirejs.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
</head>
<body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.6/require.min.js"></script>
<script src="./webpack-library-starter.amd.min.js"></script>
<script>
requirejs(["webpack-library-starter.amd"], function (lib) {
const d = new lib.Dog();
console.log(d.name);
});
</script>
</body>
</html>
from webpack-library-starter.
Related Issues (20)
- Do you think to add Prettier to the project in the future? HOT 1
- about babel plugin. HOT 1
- Yarn: unmet peer dependency HOT 1
- Include a simple demo/docs page? HOT 4
- Webpack 4 incompatible HOT 3
- Intellisense doesnโt work after transpiled HOT 2
- Unable to use produced library.js as 3rd party. HOT 10
- Webpack4, babel7 HOT 2
- Consider making it a Yeoman|whatever-generator generator ? HOT 1
- Launch dev server for index.html consuming the dev library HOT 2
- Use Source Maps in Mocha Tests HOT 1
- transpiling to ES2015? Have a potential solution. HOT 1
- Doesn't support ...spread operator?
- Transpile with statics HOT 1
- How to use dynamic import HOT 1
- Help with browser HOT 1
- webpack cli error on build
- Conceptual doubt if using this project applies to my problem HOT 2
- Module build failed: Error: Cannot find module 'babel-helper-builder-binary-assignment-operator-visitor'
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 webpack-library-starter.