minify

Angular depandency problems at minify compiling

£可爱£侵袭症+ 提交于 2019-12-12 04:32:58
问题 I have an app which uses a lot of different js files. When I compile the app normaly with gulp everything works well, but when I compile everything in one file to minify it, I get an error ( Uncaught Error: [$injector:modulerr] ). app-55bb2aca73.js:4 Uncaught Error: [$injector:modulerr] http://errors.angularjs.org/1.5.8/$injector/modulerr?p0=app&p1=Error%3A%20%…http%3A%2F%2Flocalhost%3A8080%2Fbuild%2Fjs%2Fapp-55bb2aca73.js%3A4%3A30075) at app-55bb2aca73.js:4 ... Here is my gulpfile.js (use

minify - PHP - Minify::serve - HTTP/1.0 400 Bad Request

蓝咒 提交于 2019-12-12 04:14:17
问题 I worked with minify using this doc: http://code.google.com/p/minify/wiki/CustomServer and I have problem that I can't resolve: <?php set_include_path('/srv/home/xyz/public_html/COMPONENTS/_php/minify/min/lib' . PATH_SEPARATOR . get_include_path()); require 'Minify.php'; require 'Minify/Cache/File.php'; Minify::setCache(new Minify_Cache_File()); //no error - everything is ok... until now $options = array( 'files' => array('/srv/home/xyz/public_html/test1.js', '/srv/home/xyz/public_html/test2

Minify JS files embedded with PHP code

守給你的承諾、 提交于 2019-12-12 03:56:35
问题 After long search in Google and on several Github repositories, I couldn't find anything solid (I found for HTML, not for JS) The minifiers I use for JS files mess with my PHP code, for example, if I have the file example.js.php <?php header("Content-Type: application/javascript"); $var1 = $_GET['f']; ?> //some JS and PHP code For example, the JS minifiers I use, convert $_GET['f'] to $_GET.f ; which is OK for a JS object, but not for PHP. Any ideas on how to compact the JS code leaving the

minify es2017 with gulp

自古美人都是妖i 提交于 2019-12-12 03:50:23
问题 Hey guys I'm currently using uglify-gulp with babel to minify my js. And it works great with es2015 and es2016. But it breaks if I try to do es2017. Does anyone know any workarounds to minify js that is using the new experimental features in es2017? gulp.src('build/js/bundled/bundle.js') .pipe(babel({ compact: false, presets: ["es2017", "react"], plugins: ["transform-decorators-legacy"], })) .pipe(uglify()) .pipe(gulp.dest('build/js/bundled')); which generates this error GulpUglifyError:

Looking for a CSS and for a js file merger and minimizer [closed]

泪湿孤枕 提交于 2019-12-12 01:58:15
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I'm working on a public project and one of the things we are after is a CSS file merger and minimizer and a js file merger and minimizer. The requisites are as follows: No beta code. Only stable code. Must be written in php. Must work in php 5.4. Must be compatible with php 5.3 The CSS minimizer program may be

how to remove spaces and newlines from server response?

◇◆丶佛笑我妖孽 提交于 2019-12-12 01:56:40
问题 When i request a page using browser / AJAX request i see lot of spaces and newlines which i think must be adding some overhead for retrieving the response as they too belong to characters means bytes and size. right ? Is there some way it can be removed while sending from the server ? how ? (I am using IIS and asp.net for development) 回答1: There are some http modules that make all ready what you ask For example here is one http://madskristensen.net/post/A-whitespace-removal-HTTP-module-for

MEAN.JS: Slow charging time

冷暖自知 提交于 2019-12-11 19:34:16
问题 Situation I'm using MEAN.JS framework (MongoDB, ExpressJS, AngularJS and NodeJS). I bundled and minified with grunt build all the AngularJS .js files ( Controllers, Factories, Services, Directives... ). The result are 2 files: css: 'public/dist/application.min.css', js: 'public/dist/application.min.js' Problem The file application.min.js is 266kb . When a user load the web , this file takes 5 minutes delay before the page is loaded . (Using AWS EC2). GET /dist/application.min.js 200 274.939

How to check obfuscation results of flutter app?

放肆的年华 提交于 2019-12-11 16:51:38
问题 In native android development I could check whether my minifyEnabled had taken effect. I used this script (in linux) which allows me to extract the apk and view the java files to see if my code is readable, or has been obfuscated : #! /bin/bash d2j=/work/installs/dex2jar-2.0 jdgui=/work/installs/jd-gui-1.4.0.jar apk_loc=/work/projects/my_app/build/app/outputs/app-release.apk mkdir -p /work/tmp/dex rm -rf /work/tmp/dex/* cd /work/tmp cp $apk_loc ./app-release.zip unzip app-release.zip -d dex

Removes spaces between html tags?

会有一股神秘感。 提交于 2019-12-11 11:52:20
问题 To take away some page loading time, where can I find something to remove spaces between html tags? Without me having to go through each one and remove them myself Like so: <body> <p>Lot's of space</p> </body> <body><p>No space</p></body> I found this site. But it leaves one space between tags. But I don't want any. 回答1: Be careful that you have some idea of what is happening or you will corrupt the integrity of your documents. A fully minified code sample removes all comments and all white

Compress CSS/JavaScript before publish/package

爷,独闯天下 提交于 2019-12-11 10:57:59
问题 I've been reading this post about minifying and compressing static files like CSS/JS within the publish/package event in VS2010. I wonder if it also is possible to combine the files to one CSS file and one JS file? And how that can be done in this process. 回答1: As far as minifying and compressing your CSS and JS files - that shouldn't be any issue. However - when it comes to actually combining all of your related files (CSS & JS) into single files, you will need to be careful to avoid any