ionic-gulp-primeui-copy
v1.0.1
Published
gulp package to copy primeui to the appropriate folders during an ionic build
Downloads
2
Readme
ionic-gulp-primeui-copy
Instruction provided by vevedh de CHAVIGNY on Ionic Framework forum
https://forum.ionicframework.com/t/ionic-2-projects-using-primeng-with-ionic-2/50238
integration de primeng / primeui in ionic 2 application at root application add modules run :
npm install primeui --save npm install primeng --save
in www/index.html: add before :
Now You can use sample code:
import {Page,Platform,MenuController} from 'ionic-angular'; import {Calendar} from 'primeng/primeng';
@Page({ templateUrl: 'build/pages/page1/page1.html', directives: [Calendar] }) export class Page1 { dateValue:any; ....
constructor(platform: Platform, menu: MenuController) { this.dateValue = ''; .......
} } ATTENTION You must create in node_modules directory ionic-gulp-primeui-copy with file index.js : content :
var gulp = require('gulp');
var defaultSrc = [ 'node_modules/primeui/**/.' ];
module.exports = function(options) { options.src = options.src || defaultSrc; options.dest = options.dest || 'www/build/js/primeui';
return gulp.src(options.src) .pipe(gulp.dest(options.dest)); } MODIFY gulp.js ADD
var copyPrimeui = require('ionic-gulp-primeui-copy'); ... gulp.task('primeui', copyPrimeui);