Intellisense in Visual Studio 2010

2334
4
06-16-2011 12:03 PM
IgressT
New Contributor II
Hi All,

I want to know how to enable the intellisense for the javascript in the visual studio 2010. Please read on for more information

I have developed a ASP.NET MVC3 app using VS2010 and in one of the pages I have to include a mapping application to be developed using ESRI javascript api.

In the head element of my page I have this
    
    <script src="http://serverapi.arcgisonline.com/jsapi/arcgis/?v=2.3" type="text/javascript"></script>
    <script src="http://ajax.googleapis.com/ajax/libs/dojo/1.6/dojo/dojo.xd.js" type="text/javascript"></script>
    <link href="http://serverapi.arcgisonline.com/jsapi/arcgis/2.3/js/dojo/dijit/themes/claro/claro.css" rel="stylesheet" type="text/css" />

<script type="text/javascript">
        dojo.require("esri.map");
        var map;

        function init()
        {
            var baseMapURL = "http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer";
            
            var basemap = new esri.layers.ArcGISTiledMapServiceLayer(basemapURL);

            map = new esri.Map("mapDiv");
            map.addLayer(baseMap);
        }

        dojo.addOnLoad(init);
    </script>


Everything works fine and as I said I want to know how to enable the intellisense for the javascript in the visual studio 2010.
0 Kudos
4 Replies
derekswingley1
Frequent Contributor
I can't help with enabling Intellisense (I'm not a regular VS user) but you don't need that link to dojo on the Google CDN. You get dojo when you include the ArcGIS API for JavaScript in your first script tag.
0 Kudos
IgressT
New Contributor II
I can't help with enabling Intellisense (I'm not a regular VS user) but you don't need that link to dojo on the Google CDN. You get dojo when you include the ArcGIS API for JavaScript in your first script tag.


Hi,
Thanks for the info... can you please suggest an IDE that I can use for javascript development
0 Kudos
derekswingley1
Frequent Contributor
The "Setting up a Development Environment" section of the help has some suggestions. If you're looking for Intellisense-like functionality, you might want to try Aptana Studio with the code assist plug-in.

As for an actual recommendation, personally, I prefer text editors to IDEs. MacVim/gVim is my favorite but Notepad++ is pretty solid too.
0 Kudos
nicogis
MVP Frequent Contributor
another ide for dojo is http://www.jetbrains.com/webstorm/
0 Kudos