Menu icon Foundation
Integrating 3rd party plugin with F6

I'm using a CLI installed version of sites and can't figure out how to properly include parsleyjs. I've installed it via bower, and have linked to it from layouts/default.html but I don't understand what is supposed to happen in the /dist folder. Specifically, I don't know how this external plugin is supposed to be incorporated in the dist folder so that if functions as expected.

jqueryplugins

I'm using a CLI installed version of sites and can't figure out how to properly include parsleyjs. I've installed it via bower, and have linked to it from layouts/default.html but I don't understand what is supposed to happen in the /dist folder. Specifically, I don't know how this external plugin is supposed to be incorporated in the dist folder so that if functions as expected.

Rafi Benkual over 3 years ago

Good question - it is supposed to be copied over.

I wrote an answer here that should help: http://foundation.zurb.com/forum/posts/36974-enhancing-foundation-with-bower-components

Travis Fulton over 3 years ago

Thanks for the reply, however my gulpfile.babel.js file is laid out differently than the gulpfile in your other post. I understand that I need to point to the plugin file in bower_components, I'm just unsure of the syntax. Thanks!

 

function javascript() {

  return gulp.src(PATHS.javascript)

    .pipe($.sourcemaps.init())

    .pipe($.babel())

    .pipe($.concat('app.js'))

    .pipe($.if(PRODUCTION, $.uglify()

      .on('error', e => { console.log(e); })

    ))

    .pipe($.if(!PRODUCTION, $.sourcemaps.write()))

    .pipe(gulp.dest(PATHS.dist + '/assets/js'));

}

 

foundation 6.2.1