Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

443
Visualizações
How to access a javascript function from inside an angular module?

I use a piece of code in angularjs (coded by an ex-member of the company). I know nothing about angularjs, but I would like to access a javascript variable or a function, so that I can use it within the angular module. Below, is an example of what my problem is...

Angularjs part:

(function(){
    var app = angular.module('project', [],
        function($locationProvider){$locationProvider.html5Mode(true);}
    );

... other angularjs functions ...

})();

Javascript part:

var price = 10000;

function getPrice(){
     return price;
}

I think this question seems very simple to answer, but I have been stuck for hours and I feel kind of "desperate" not to be able to resolve it. Thanks in advance for your suggestions

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda