Skip to content

Commit

Permalink
Added SystemJS config to demo app
Browse files Browse the repository at this point in the history
  • Loading branch information
edcarroll committed Mar 28, 2017
1 parent 0fccc91 commit a6a605e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
4 changes: 4 additions & 0 deletions demo/src/app/pages/getting-started/getting-started.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ <h2 class="ui dividing header">Installation</h2>
<demo-codeblock language="typescript" [src]="individualImportCode"></demo-codeblock>
</div>
<p>Now you're good to go!</p>
<p><strong>Note</strong> if you're using SystemJS, add the following to your <code>systemjs.config.js</code> file:</p>
<div class="ui segment">
<demo-codeblock language="typescript" [src]="systemJSCode"></demo-codeblock>
</div>
<h2 class="ui dividing header">Dependencies</h2>
<div class="ui bulleted list">
<div class="item"><a href="https://angular.io">Angular 2</a> (^4.0.0)</div>
Expand Down
11 changes: 10 additions & 1 deletion demo/src/app/pages/getting-started/getting-started.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { Component } from '@angular/core';
})
export class GettingStartedPage {
public installCode:string = `$ npm install ng2-semantic-ui --save`;
public includeCssCode:string = `<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.4/semantic.min.css">`;
public includeCssCode:string = `<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.9/semantic.min.css">`;
public importCode:string = `import {SuiModule} from 'ng2-semantic-ui';`;
public moduleImportCode:string = `
import {SuiModule} from 'ng2-semantic-ui';
Expand All @@ -23,6 +23,15 @@ import {SuiModule} from 'ng2-semantic-ui';
bootstrap: [AppComponent]
})
export class AppModule {}
`;
public systemJSCode:string = `
var config = {
...
map: {
...
'ng2-semantic-ui': 'npm:ng2-semantic-ui/bundles/ng2-semantic-ui.umd.min.js'
}
}
`;
public individualImportCode:string = `import {SuiCheckboxModule, SuiRatingModule} from 'ng2-semantic-ui';`;
}

0 comments on commit a6a605e

Please sign in to comment.