Mercurial > hg > ugly-duckling
changeset 36:e58fb181a11d
Import waves-ui with TypeScript (ambient module, no typings for now) over angular-cli global scripts. Include there instead a TypeScript file, for creating a webpack scripts bundle of external modules (unused currently, but can provide a way for importing npm modules to a worker).
author | Lucas Thompson <dev@lucas.im> |
---|---|
date | Thu, 01 Dec 2016 14:05:49 +0000 |
parents | 47ea1f5af71f |
children | f6e58c2accb0 |
files | angular-cli.json src/app/waveform/waveform.component.ts src/app/waveform/waves-ui.d.ts |
diffstat | 3 files changed, 6 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/angular-cli.json Thu Dec 01 10:35:46 2016 +0000 +++ b/angular-cli.json Thu Dec 01 14:05:49 2016 +0000 @@ -21,7 +21,7 @@ "styles.css" ], "scripts": [ - "../node_modules/waves-ui/waves-ui.min.js" + "externals.ts" ], "environments": { "source": "environments/environment.ts",
--- a/src/app/waveform/waveform.component.ts Thu Dec 01 10:35:46 2016 +0000 +++ b/src/app/waveform/waveform.component.ts Thu Dec 01 14:05:49 2016 +0000 @@ -2,8 +2,8 @@ Component, OnInit, ViewChild, ElementRef, Input, AfterViewInit, NgZone } from '@angular/core'; import {AudioPlayerService} from "../services/audio-player.service"; +import wavesUI from 'waves-ui'; -declare let wavesUI: any; // TODO non-global app scope import type Timeline = any; // TODO what type actually is it.. start a .d.ts for waves-ui? @Component({