Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4004048
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T08:13:32+00:00 2026-05-20T08:13:32+00:00

I am writing some scripts that I broke up into separate files. I am

  • 0

I am writing some scripts that I broke up into separate files. I am wondering is it possible to get intellisense working on my custom scripts.

Say I have Script A with some functions that I need to use in Script B. It would be cool if I could see those functions in Script B while I am typing.

I tried to do the xml reference comment

/// <reference path="A.js" />

but this does not seem to do anything.

Thanks

Edit

// script 1

var abc = (function (my, $)
{
    my.events = function ()
   {
        // selectors is from my base file(not shown as I don't think it is needed to be shown)
        // my.selectors.createFrm = '#createFrm'
        var createSubmitFrmHandler = $(my.selectors.createFrm).live('submit', function (e)
        {
            e.preventDefault();
        });

   }

   return my;

} abc || {}, jQuery));

// script 2

var abc = (function (my, $)
{
     my.dialogs = {

        addDialog: function ()
        {
            var $dialog = $('<div></div>').dialog(
            {
                width: 580,
                height: 410,
                resizable: false,
                modal: true,
                autoOpen: false,
                title: 'Basic Dialog',
                buttons:
                    {
                        Cancel: function ()
                        {
                            $(this).dialog('close');
                        },
                        'Create': function ()
                        {

                            jQuery.validator.unobtrusive.parse(my.selectors.createFrm)
                            // this is undefined as page loadup no form was found so live did not kick in
                            my.createSubmitFrmHandler.validate().form();

                        }
                    }
            });

            return $dialog;
        },

    return my;
} abc || {}, jQuery));

So I have something like that.

If I am in Script 2 if I go to “my.” I see nothing in intellisense.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T08:13:32+00:00Added an answer on May 20, 2026 at 8:13 am

    I declare my function in a file (JScript1.js) and add in the intellisense (the comments)

    var myFunc = function (myParam) {
        /// <summary>
        /// This is my summary
        /// </summary>
        /// <param name="myParam" type="String">
        /// This the comment for the parameter
        /// </param>
        /// <returns type="Array" />
    }
    

    I added ///<reference path="JScript1.js" to the top of my second script (JScript2.js) and intellisense was available.
    I moved the file to a different folder, lost intellisense and then updated the path to be the relative path ///<reference path="../Models/JScript1.js" and intellisense was available again.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing some scripts that are using the HTML 5 file API in FireFox
I'm writing some unix-style Ruby scripts that take option flags. Normally, I write a
Apologies for what is probably a newbish question. I am writing some Powershell scripts
I have some scripts that ought to have stopped running but hang around forever.
I've been writing some scripts for a game, the scripts are written in Lua.
I'm writing some scripts in Ruby, and I need to interface with some non-Ruby
For my current job I am writing some long-running (think hours to days) scripts
I downloaded the most recent version of Android for Linux (android-sdk_r05-linux_86.tgz). I was trying
I'm looking to re-organize the way we release our internal software. All of the
I want to deploy my site on my web hosting package by doing a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.