Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate SystemJS.config() in config.jspm.js #1908

Closed
mrhyde opened this issue Jun 12, 2016 · 3 comments
Closed

Duplicate SystemJS.config() in config.jspm.js #1908

mrhyde opened this issue Jun 12, 2016 · 3 comments

Comments

@mrhyde
Copy link

mrhyde commented Jun 12, 2016

I'm trying to dive into jspm@0.17 and it's just keep hitting me with questionable code and solutions...
For example in 0.16 in config file we had one System.config() call, but in 0.17 there is now two of them after jspm init

SystemJS.config({        ## <--------- FIRST
  browserConfig: {
    'baseURL': '/',
    'paths': {
      'npm:': 'assets/scripts/jspm_packages/npm/',
      'playground/': 'assets/scripts/'
    }
  },
  nodeConfig: {
    'paths': {
      'npm:': 'temp/jspm_packages/npm/',
      'playground/': 'source/scripts/'
    }
  },
  devConfig: {
    'map': {
      'plugin-babel': 'npm:systemjs-plugin-babel@0.0.12'
    }
  },
  transpiler: 'plugin-babel',
  packages: {            ## <------------ LOCAL PACKAGES
    'playground': {
      'main': 'main.js',
      'format': 'esm',
      'meta': {
        '*.js': {
          'loader': 'plugin-babel'
        }
      }
    }
  }
})

SystemJS.config({        ## <------------ SECOND
  packageConfigPaths: [
    'npm:@*/*.json',
    'npm:*.json'
  ],
  map: {},
  packages: {}           ## <----------- REMOTE PACKAGES (npm, github)
})
@guybedford
Copy link
Member

This was to make it easier to distinguish what is user-config and automatically managed dependency configuration, but I'm also not 100% sure about it yet either.

@frederikschubert
Copy link
Contributor

I like this behavior. But I guess it would be good to insert a comment for the generated config part that states that this part is automatically generated.

@ArmorDarks
Copy link

@guybedford Maybe it would be better to keep issue open then for now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants