DoneJS StealJS jQuery ++ FuncUnit DocumentJS
3.0.0
2.3.27

 

  • Github
  • Twitter
  • Chat
  • Forum
  • Guides
  • Core
  • Ecosystem
    • can-construct-super
    • can-define-stream
    • can-fixture
    • can-fixture-socket
    • can-jquery
    • can-stache-converters
    • can-stream
    • can-vdom
    • can-view-import
      • Pages
        • Dynamic Imports
        • Static Imports
      • Attributes
        • can-tag
        • from
        • {^value}
    • can-zone
    • steal-stache
  • Infrastructure
  • Legacy
  • Bitovi
    • Bitovi.com
    • Blog
    • Consulting
    • Training
    • Open Source
  • Chat
  • Forum
  • Star
  • Follow @canjs
  • CanJS
  • /
  • Ecosystem
  • /
  • can-view-import
  • /
  • Static Imports
  • / On this page
    • Static Imports

      page

      Static imports reflect direct dependencies of this template. Most uses of can-view-import will be to static imports.

      • source

      To make your import be static, it must be self closing like />.

      Example

      <can-import from="mymodule" />
      

      which is equivalent to a ES6 import like:

      import from "mymodule";
      

      CanJS is part of DoneJS. Created and maintained by the core DoneJS team and Bitovi. Currently 3.0.0.