With StealJS, you can import this module directly in a template that is autorendered:
import plugin from 'can-fragment';
Use require
to load can-fragment
and everything else
needed to create a template that uses can-fragment
:
var plugin = require("can-fragment");
Load the global
version of the plugin:
<script src='./node_modules/can-fragment/dist/global/can-fragment.js'></script>
This plugin is one of many. Check out all of the DoneJS plugins on NPM.