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

  • SEARCH
  • Home
  • 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 7704897
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T23:47:02+00:00 2026-05-31T23:47:02+00:00

I have a Host Javascript Application, which not use AMD, BackboneJS or RequireJS but

  • 0

I have a Host Javascript Application, which not use AMD, BackboneJS or RequireJS but use jQuery, and i have a small application with requireJS + BackboneJS, which should be a plugin of the Host.

Now the plugin AMD-Application :

  1. should become some data from the Host application
  2. should be started from the Host application(into a jquery Dialog)

My problem is that i dont have any globals variables(functions) in the plugin AMD-application, so my big non-AMD App can’t see it this way.

How can i set the communication between this both, so that the non-AMD App can see and pass data to the plugin AMD App ?

Entry point my plugin AMD App :

<script data-main="app/js/main" src="app/js/Libs/require/require.js"></script>

main.js

require.config({
  paths: {
    jquery: 'http://code.jquery.com/jquery-1.7.1.min',
    jqueryui: 'http://code.jquery.com/ui/1.8.17/jquery-ui',
    underscore: 'Libs/underscore/underscore-min',
    backbone: 'Libs/backbone/backbone-min',

    //Require Plugins
    text: 'Libs/require/text',
    use: 'Libs/require/use',
    domReady: 'Libs/require/domReady'
  },
  use: {
    backbone: {
      deps: ["use!underscore", "jquery"],
      attach: function() {
        return Backbone;
      }
    },    
    underscore: {
      attach: "_"
    }
  }
});


require([
    'jquery',
    'use!backbone',
    'app'
    ], function(App){

    });

app.js

define([
 'jquery',
 'router'
 ], function($, Router){
    var initialize = function(){
     // Pass in our Router module and call it's initialize function
     Router.initialize();
    }
    return {
      initialize: initialize
    };
 });
  • 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-31T23:47:03+00:00Added an answer on May 31, 2026 at 11:47 pm

    Not sure I completely understand, but to expose a global from your requirejs code:

    require([
      'jquery',
      'use!backbone',
      'app'
    ], function(App){
      window.App = App;
    });
    

    Now window.App is visible to all the code.

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

Sidebar

Related Questions

I am working on a rails application that uses big javascript libraries (e.g. jquery
I'm starting to write a small web application and have started thinking about securing
I have been asked to integrate facebook chat in my application using javascript. I
We have an application in which we have created a service layer with most
I know this question has been asked many times, but I have not been
I have an unattended touch screen kiosk application which needs to be able to
I have a htaccess file that it work perfectly on host but when I
I have a host with php+mysql and i need to run a script here
A single Biztalk Server can have multiple Host processes. Is it possible to create
Here's the scenario: I'd like to have a host class that can have 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.