Permalink
Browse files

More micromodules; A lot of minor optimizations to performance and gz…

…ip ratio
  • Loading branch information...
dcodeIO committed Dec 12, 2016
1 parent 28a1d26 commit ce41d0ef21cee2d918bdc5c3b542d3b7638b6ead
@@ -91,7 +91,7 @@
"no-catch-shadow": 1,
"no-label-var": 1,
"no-restricted-globals": 1,
"no-return-assign": 1,
"no-return-assign": 0, // can make sense.
"no-shadow-restricted-names": 1,
"no-shadow": 0, // this is javascript. it has forEach and all that stuff.
"no-undef-init": 1,
@@ -113,7 +113,8 @@
// Stylistic Issues
"semi": 1, // maybe next time
"no-extra-semi": 1
"no-extra-semi": 1,
"quotes": 1 // useful for gzip
// ECMAScript 6 // maybe next time
}
@@ -6,8 +6,11 @@ types/types.d.ts
bench.txt
docs/
examples/
src/util/aspromise/
src/util/base64/
src/util/codegen/
src/util/eventemitter/
src/util/fetch/
src/util/fs/
src/util/pool/
src/util/utf8/
@@ -371,7 +371,7 @@ $> npm run types
protobuf.js integrates into any browserify build-process. There are a few possible tweaks:
* If performance is a concern or IE8 support is required, you should make sure to exclude the browserified `buffer` module and let protobuf.js do its thing with Uint8Array/Array instead.
* If you do not need int64 support, you can exclude the `long` module.
* If you do not need int64 support, you can explicitly exclude the `long` module. It will be included otherwise.
* If your application does not rely on the following modules and package size is a concern, you can also exclude `process` , `_process` and `fs`.
* If you have any special requirements, there is [the bundler](https://github.com/dcodeIO/protobuf.js/blob/master/scripts/bundle.js) as a reference.
@@ -128,8 +128,6 @@ function buildFunction(type, functionName, gen, scope) {
}).join(',') + "]);");
push("return " + lines[0]);
lines.slice(1).forEach(function(line) {
if (line === '\t"use strict"')
return;
var prev = indent;
var i = 0;
while (line.charAt(i++) === "\t")
Oops, something went wrong.

0 comments on commit ce41d0e

Please sign in to comment.