Skip to content

Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules

License

Notifications You must be signed in to change notification settings

HuasoFoundries/systemjs-glsl-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

systemjs-glsl-plugin

Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules. Made for jspm@0.17

This plugin is, for now, a POC to load *.glsl files (such as the ones found on the THREE.js source ) and let SystemJS treat them as javascript ES6 modules.

I made this loader to import some specific THREE.js submodules into one of my projects, then building a static build with jspm-cli, and getting Rollup to perform its three shaking magic on the result.

Installation

Install it with jspm using:

jspm install glsl=npm:systemjs-glsl-plugin

Config

This loader must be enabled in the meta section of jspm.config.js

meta: {
  "*.glsl": {
    "defaultExtension": false,
    "loader": "glsl"
  },{
    ...  
  }
}

About

Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published