|
Rank: Newbie Groups: Member
Joined: 8/13/2019 Posts: 3
|
Hello, good morning
I am trying to use the JSExtension in my Angular project as complement of my c# application. On my c# project there are no problem, but when i try to implement it in my Angular project I get the "Cannot find name 'eoapi'." error.
Is there a node package to include in my project to make reference to the eoapi? or how can i make reference to and include the eoapi object in my component?
Using EO v19.1.40.0.
thanks in advance!
Jessica
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,218
|
Hi,
I am not sure if I understand your question. The variable "eoapi" only exists when you run the page inside EO.WebBrowser. If you run the page on a regular web browser such as Google Chrome, then it would not exist.
Thanks!
|
|
Rank: Newbie Groups: Member
Joined: 8/13/2019 Posts: 3
|
Hi!, thanks for your response :)
I did some tests using a single .js file, yes, as you mentioned it only exists when the page inside is running on EO.WebBrowser My problem is when I want to include it using typescript and to build my angular project.
I think maybe I need to include an external single js file. I will try it..
Thank you so much!
Jessica
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,218
|
Hi, You can write code to test if eoapi exists before using it. See here for more details: https://www.essentialobjects.com/doc/common/eo_js.aspx#checkThanks!
|
|