Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anyway to get intellisense into define blocks as well? #1

Open
david-driscoll opened this issue Apr 8, 2012 · 7 comments
Open

Anyway to get intellisense into define blocks as well? #1

david-driscoll opened this issue Apr 8, 2012 · 7 comments

Comments

@david-driscoll
Copy link

This is a pretty cool little addition. I've tried to hack onto it a little bit, to get intellisense also when working inside define blocks, but I've had no luck so far.

Is there any chance that is a pretty quick fix to make this also work inside define blocks?

@jrburke
Copy link
Owner

jrburke commented Apr 10, 2012

Glad to hear someone trying it out. This is still "under construction".

I'm still getting set up with windows 8 (my vm was too small to install the visual studio beta), so I'm a bit behind on this. @lostintangent might have an idea though in the meantime.

@david-driscoll
Copy link
Author

I figured it was very much still alpha, pre-alpha considering VS11 is still in beta itself. I just thought maybe you have some insight. I'll have another shot at it in a week or so, depends on how much work takes of my spare time.

I think the behaviour has to do with what happens inside RequireJS when define is called, instead of require. Obviously it makes sense, since define doesn't invoke the code block until it's required.

I tried to make define fake a require call in the intellisense portion and occasionally that worked, other times it would outright crash VS11. I probably just need a better way to fake the require, so it only happens for the first define, and none of the others that come after it.

We have a pretty complex dependency graph, so being able to access intellisense inside define blocks would be pretty nice.

@gudmundurh
Copy link

I'm pretty excited as well - but havn't had any luck getting this to work. Is it VS11 only? (A link to some reference of the mysterious intellisense global would be most welcome, I can't seem to find anything on it.)

Keep up the good work!

@jrburke
Copy link
Owner

jrburke commented Apr 29, 2012

@gudmundurh I believe this is only for the visual studio beta that can be installed into the Windows 8 consumer preview, so for that version of visual studio.

@david-driscoll
Copy link
Author

It works with VS11 beta in general.
The intellisene object has proper definitions for its methods, it just
doesn't show up as attached to the window ( and it shouldn't it is a vs
convention. )

I still have yet to find a reliable way for it to work in define blocks but
for now I'm leaving it alone, I'm waiting to see if some more bugs get
fixed in a later release.
On Apr 29, 2012 1:12 PM, "James Burke" <
reply@reply.github.com>
wrote:

@gudmundurh I believe this is only for the visual studio beta that can be
installed into the Windows 8 consumer preview, so for that version of
visual studio.


Reply to this email directly or view it on GitHub:

#1 (comment)

@orand
Copy link
Contributor

orand commented Aug 18, 2012

@gudmundurh Documentation for the intellisense object can be found here.

@orand
Copy link
Contributor

orand commented Aug 18, 2012

I just submittted a pull request that makes intellisense work inside define, at least on my machine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants