Skip to content

Comment on Require.js Library Skeleton

Comments

The main file is exporting a global variable (window.mylib) directly, when it should assume require.js is present and export itself as a module. Only when creating a stand-alone/static build for non-requirejs environments it should export a global. CommonJS support could be added too.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.