These are chat archives for systemjs/systemjs

Aug 2016
Aug 16 2016 08:17
anyone here?
Caige Nichols
Aug 16 2016 21:59
I am
Miguel Couto
Aug 16 2016 22:58
hi guys
i am trying to setup systemjs
i have install systemjs with
npm install systemjs
then in index.html i added this code.
  <script src="/node_modules/systemjs/dist/system.js"></script>
  // set our baseURL reference path
      baseURL: '/',
      map: {
        'app': 'dist/ts'
      packages: {
         'app': {
           main: 'index.js',
           format: 'cjs',
           defaultExtension: 'js',

    // loads /dist/ts/main.js
now the problem is that i use typescript to compile Typescript to commonjs
so my TS is
// main.ts
import {ABC} from './test';


// test.ts
export const ABC = "ABC TEST OK";
my Js generated is
// main.js
"use strict";
var test_1 = require('./test');
// test.js
"use strict";
exports.ABC = "ABC TEST OK";
Miguel Couto
Aug 16 2016 23:03
when i load the browser i get "main.ts:1 Uncaught ReferenceError: require is not defined"