jspm

Component rendered as comment in VueJS + JSPM

心已入冬 提交于 2019-12-04 10:02:17
I tried to build simple app using jspm with vue.js. This is my html file: <html> <head> <script src="bundle.js"></script> <!--script src="jspm_packages/npm/vue@2.1.10/dist/vue.min.js"></script--> </head> <body> <div id="app"> {{ message }} </div> </body> </html> My main.js file: import Vue from "vue" const app = new Vue({ el: '#app', data: { message: 'Hello Vue!' } }); I'm building self-executing bundle like this: jspm bundle-sfx main.js bundle.js When I open browser I can see that node div#app is replaced by comment node. You can also see comment node in $el in Vue object: When I use Vue from

Typescript Compiler error TS2307: Cannot find module 'jquery'

大城市里の小女人 提交于 2019-12-04 04:31:25
I was following JSPM getting started guide and I want to install jquery package so I execute below command. jspm install jquery But when I try to import it in typescript like below import $ from 'jquery' I'm getting a error from typescript compiler saying error TS2307: Cannot find module 'jquery'. Not only for this library for other libraries I'm getting the same error. You need to include type definitions for jquery in the compilation context, you can grab them from https://github.com/DefinitelyTyped/DefinitelyTyped 来源: https://stackoverflow.com/questions/35102441/typescript-compiler-error

Unexpected value 'FileUploadModule' imported by the module 'UploaderModule' - ng2-file-upload

好久不见. 提交于 2019-12-04 03:31:32
问题 Using angular 2.0.1 (release) and ng2-file-upload 1.1.0 (latest version) I am getting the above error upon running this code. I am using jspm with systemjs to bundle my app (all fully up-to-date). import {Component, NgModule} from '@angular/core'; import {CommonModule} from '@angular/common'; import {FileUploadModule} from 'ng2-file-upload'; @Component({ selector: 'uploader', templateUrl: '/build/templates/uploader.html' }) export class UploaderComponent { uploader = new FileUploader({url: '

change jspm_packages location

半世苍凉 提交于 2019-12-03 12:00:53
Is there a .bowerrc equivalent in jspm ? When I run jspm install , I'd like jspm to install the packages to client/jspm_packages folder. How can I configure jspm to change location of jspm_packages folder? Thanks sheldon_cooper I found it. In your package.json , add the path into packages inside directories . "jspm": { "directories": { "packages": "new/path/to/jspm_packages" } } 来源: https://stackoverflow.com/questions/29902646/change-jspm-packages-location

jspm / jQuery / TypeScript - module “jquery” has no default export

冷暖自知 提交于 2019-12-03 10:43:33
问题 I'm trying to bootstrap a web app using TypeScript and jspm & system.js for module loading. I'm not getting very far. After installing jspm, and using it to install jQuery: jspm install jquery And the basics: <script src="jspm_packages/system.js"></script> <script src="config.js"></script> <script> System.import('main'); </script> main.ts: import $ from "jquery"; export class Application { constructor() { console.log($); } } The TypeScript won't compile because "Module 'jquery' has no default

Using SASS with Aurelia's Skeleton Navigation project

馋奶兔 提交于 2019-12-03 08:14:18
var gulp = require('gulp'); var sass = require('gulp-sass'); var runSequence = require('run-sequence'); var changed = require('gulp-changed'); var plumber = require('gulp-plumber'); var to5 = require('gulp-babel'); var sourcemaps = require('gulp-sourcemaps'); var paths = require('../paths'); var compilerOptions = require('../babel-options'); var assign = Object.assign || require('object.assign'); // transpiles changed es6 files to SystemJS format // the plumber() call prevents 'pipe breaking' caused // by errors from other gulp plugins // https://www.npmjs.com/package/gulp-plumber gulp.task(

How to bundle Angular 2 Typescript app using Gulp and SystemJS?

感情迁移 提交于 2019-12-03 04:50:17
问题 I'm using Typescript with SystemJS for module loading and Gulp for task runner in my Angular 2 project. The current version of Angular in the project is RC2 but the problem is present also with RC1. I followed the steps of brando's answer here. After bundling my application and initial load of the website SystemJS throws error: Error: http://localhost:57462/app/app.bundle.js detected as register but didn't execute. The application works but the error in the console definitely is not a good

Package Manager: Bower vs jspm

会有一股神秘感。 提交于 2019-12-03 02:02:07
问题 How is Bower different than jspm? Can Bower provide jspm functionality about SystemJS universal module loader? 回答1: Well JSPM is much larger and ambitious project than Bower. Bower has only one purpose-to download source files you need from the web to your hard disk. For you as a consumer, bower doesn't do anything else. If you want to execute script files from bower, you need to create your script tags for each of them. While jspm is not only a module downloader. It downloads by default

jspm / jQuery / TypeScript - module “jquery” has no default export

老子叫甜甜 提交于 2019-12-03 01:14:07
I'm trying to bootstrap a web app using TypeScript and jspm & system.js for module loading. I'm not getting very far. After installing jspm, and using it to install jQuery: jspm install jquery And the basics: <script src="jspm_packages/system.js"></script> <script src="config.js"></script> <script> System.import('main'); </script> main.ts: import $ from "jquery"; export class Application { constructor() { console.log($); } } The TypeScript won't compile because "Module 'jquery' has no default export. The generated config.js has the correct mapping: "jquery": "npm:jquery@2.2.0" When the module

How to bundle Angular 2 Typescript app using Gulp and SystemJS?

给你一囗甜甜゛ 提交于 2019-12-02 19:09:46
I'm using Typescript with SystemJS for module loading and Gulp for task runner in my Angular 2 project. The current version of Angular in the project is RC2 but the problem is present also with RC1. I followed the steps of brando's answer here . After bundling my application and initial load of the website SystemJS throws error: Error: http://localhost:57462/app/app.bundle.js detected as register but didn't execute. The application works but the error in the console definitely is not a good thing. I tested my configuration on empty project and the problem is present again so I think the