.. from a seasoned JSPack'er...
Semi Colons are needed on everyline for the JSPack Program
(see www.dansteinman.com and I have written a v0.1.1 BUG fix for it as
well).
Dan Will update the site maybe (else, find it attached)
Anyways, Semi-colons are required when packing:
eg
function foobar(foo) {
bar = foo + 'bar'
return bar
}
Run that through the JSPack and you get
functon foobar(foo){bar=foo+'bar'return bar}
NOT what you want .. you want
functon foobar(foo){bar=foo+'bar';return bar;}
thus the Semis are needed .. and just to give JSPack it's rightful place
On a site we are under development with currently:
JSPacking has saved us 35k in useless JavaScript Code.
Not a bad saving when we are in the space saving industry of
websites, yadda yadda yadda
Personal Preference in personal code YES
Required When wanting to optimise a site
Having said that .. A JavaScript 'Compiler/Compressor' Would
be better, this requires writing a Parser .. I half have my hand up ;)
Any helpers ?
-----Original Message-----
From: Stephan Tolksdorf [mailto:[EMAIL PROTECTED]]
Sent: Thursday, 7 June 2001 10:12 AM
To: Doug Melvin
Subject: Re[4]: [Dynapi-Dev] DynAPI && ESC
>semi colons make code more understandable to OTHER people.
Sorry, but this absolute statement is rubbish. I'd propose
to take a look at the scripting language Python or some functional
languages.
There are many ways to layout your code and certainly some are more
human readable than the C-like way.
Semicolons in Javascript are most often just superfluous. I don't see
why a semicolon at the end of every line should make the code more
readable.
You could still say it's a matter of personal taste...
Stephan
_______________________________________________
Dynapi-Dev mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-dev
jspack-0.1.1.zip