I am looking for a better glob pattern for usemin, i want to to find all .js files but exclude the .spec.js files. I have the following solution so far.  <script src="components/**/*(.js|!(*.spec.js|*.scss))"></script>   The solut...
I've been having an issue with grunt-usemin where it doesn't replace the non-revved reference block with the single revved line. The two files in the reference block get concatenated and uglified just fine; the single file metadata.min.js als...
For example: Im using the current configuration below to uglify my JS scripts in my Gruntfile:      uglify: {         options: {             report: "min", //"gzip",             sourceMap: true,             preserveComments: false, //...
Is there a way to substitute variables in javascript files, with a preprocessor during build process. I uses grunt, usemin, uglifyjs (part of yeoman stack).   I currently refer to url from a global javascript object. For example,   my.url = {      bo...
I'm setting some markers on a Google map in an angular project.  And they work correctly in the dev enviroment, but once they are built into the dist folder they can not be found.    My markers code is like so:  $http.get("json/locations.json...
let index = $scope.fetchPanelAssessorDetails.findIndex ( assessor => assessor.name === assessorDet.name );   I tried fetching the index of the object using above code. It worked too, but it affects my minification and uglification of code using g...
I would like to replace url("images/ string to some other string e.g. ZZZZZZZZZZZZ using grunt-replace.  I use following configuration:  replace: {     dist: {         options: {             patterns: [                 {                     match...
I have a Gruntfile.js which compiles jade templates, scss files, coffeescript etc and then uses useminPrepare to generate the config for concat, uglify etc an rewrite the source using ` blocks.  This all works but I'm using multiple .jade files t...
I have the following in my gruntfile:  usemin: {     html: ['<%= yeoman.dist %>/**/*.html'],     css: ['<%= yeoman.dist %>/styles/**/*.css'],     js: ['<%= yeoman.dist %>/scripts/**/*.js'],     options: {...
I recently did some optimizations to improve the score of the application I'm working on (AngularJS) in the Pagespeed tool from the Google webmaster tools.  Specifically, Google was asking to "Eliminate render-blocking JavaScript and CSS in a...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.