apply JsType to entire assembly

33 views
Skip to first unread message

Ryan Fuller

unread,
May 15, 2013, 2:52:18 PM5/15/13
to shar...@googlegroups.com
I'm using [assembly: JsType(JsMode.Prototype, Filename = "~/../MyProject/Scripts/MyScripts.js")] in my AssemblyInfo.cs class. I'm trying to apply that attribute to every class in the assembly so that every class is output to the specified file. However it's not working. Classes that do not have the JsType attribute applied directly to them do not output to the specified file. Instead, they output to the default file ("/res/assemblyName.js") instead and every type in that file is named "Array" instead of the actual name of the Type. Classes that DO have the JsType attribute applied directly to them work as expected. Can you tell me what's going on and how to fix this?

-Ryan

Dan-el Khen

unread,
May 15, 2013, 3:05:36 PM5/15/13
to shar...@googlegroups.com
Hi Ryan,

It sounds like a bug, but try this:
[assembly: JsExport(DefaultFilename= "~/../MyProject/Scripts/MyScripts.js")]

This is a more general way of saying the same thing.

Cheers
Dan-el


On Wed, May 15, 2013 at 9:52 PM, Ryan Fuller <rfu...@gmail.com> wrote:
I'm using [assembly: JsType(JsMode.Prototype, Filename = "~/../MyProject/Scripts/MyScripts.js")] in my AssemblyInfo.cs class. I'm trying to apply that attribute to every class in the assembly so that every class is output to the specified file. However it's not working. Classes that do not have the JsType attribute applied directly to them do not output to the specified file. Instead, they output to the default file ("/res/assemblyName.js") instead and every type in that file is named "Array" instead of the actual name of the Type. Classes that DO have the JsType attribute applied directly to them work as expected. Can you tell me what's going on and how to fix this?

-Ryan

--
You received this message because you are subscribed to the Google Groups "SharpKit Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sharpkit+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Ryan Fuller

unread,
May 15, 2013, 3:14:43 PM5/15/13
to shar...@googlegroups.com
That did not fix it. I'm still seeing the same behavior.

Dan-el Khen

unread,
May 26, 2013, 8:44:36 AM5/26/13
to shar...@googlegroups.com
Hi Ryan, I didn't forget about you, I'll try to check this out soon.

Dan-el

Ryan Fuller

unread,
Jun 6, 2013, 10:56:04 AM6/6/13
to shar...@googlegroups.com
No problem. For now I'm just putting the attribute on all my classes so it's no biggie.

-Ryan

Dan-el Khen

unread,
Jun 6, 2013, 10:57:39 AM6/6/13
to shar...@googlegroups.com
Ok, there are few issues regarding metadata inheritance, they should all be checked.

Thanks!
Dan-el
Reply all
Reply to author
Forward
0 new messages