Google Visualization external

116 views
Skip to first unread message

Bradley Mclain

unread,
May 2, 2012, 9:29:57 PM5/2/12
to Closure Compiler Discuss
Hi,

Was looking to use Google Visualization with closure and noticed there
was no external available for it yet.

On the Google Visualization homepage there is a js file available for
use with autocomplete in IDE's. With some modification (mainly adding
compiler directive comments) could this file also be acceptable as an
external for the closure compiler?

Here is the link to the file:
http://www.google.com/uds/modules/gviz/gviz-api.js

Thanks,

Brad

John Lenz

unread,
May 3, 2012, 2:30:14 PM5/3/12
to closure-comp...@googlegroups.com
I think that you simply would need to add /** @constructor */ to functions callable with "new".    Everything else is gravy. 

Nick Santos

unread,
May 3, 2012, 2:34:25 PM5/3/12
to closure-comp...@googlegroups.com
I forwarded your email to the folks that maintain gviz-api.js. And yes, the only real difference between the externs file I use and the file you pointed to is that it has a bunch of @constructor annotations.

Nick

bradley.ja...@gmail.com

unread,
May 6, 2012, 8:00:31 PM5/6/12
to closure-comp...@googlegroups.com
Thanks guys.

So if I or someone else makes the appropriate changes, could the file get added to the repository under http://closure-compiler.googlecode.com/svn/trunk/contrib/externs?


On Friday, May 4, 2012 4:34:25 AM UTC+10, Nick Santos wrote:
I forwarded your email to the folks that maintain gviz-api.js. And yes, the only real difference between the externs file I use and the file you pointed to is that it has a bunch of @constructor annotations.

Nick

John Lenz

unread,
May 7, 2012, 10:47:45 AM5/7/12
to closure-comp...@googlegroups.com
Yep.

Chad Killingsworth

unread,
May 7, 2012, 12:08:55 PM5/7/12
to closure-comp...@googlegroups.com
Just post an issue on the issue tracker with your new file and make sure you have signed a CLA as listed in the CONTRIBUTORS file.


On Monday, May 7, 2012 9:47:45 AM UTC-5, John wrote:
Yep.
Reply all
Reply to author
Forward
0 new messages