Skip to content

Commit

Permalink
feat: support ESM and CJS (1st draft) #35
Browse files Browse the repository at this point in the history
  • Loading branch information
ianmcburnie committed Dec 8, 2021
1 parent 84776fe commit 5643597
Show file tree
Hide file tree
Showing 13 changed files with 814 additions and 290 deletions.
5 changes: 4 additions & 1 deletion docs/makeup-switch/index.js
@@ -1,7 +1,10 @@
import "../docs.css";
import "@ebay/skin/switch";

const MakeupSwitch = require('../../packages/makeup-switch');
// CJS
//const MakeupSwitch = require('../../packages/makeup-switch').default;
// MJS
import MakeupSwitch from '../../packages/makeup-switch';

window.onload = function() {
document.querySelectorAll('.switch').forEach(function(el, i) {
Expand Down
2 changes: 1 addition & 1 deletion docs/makeup-switch/index.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 5643597

Please sign in to comment.