Getting Cesium to work with Angular 7

:smiley: lolz, good to know. 7 minutes would be superhuman, but I was fully ready to accept the presence of Code Superman.
We can use angular-cesium or not–either is good!

Whenever you’re ready to push up your changes, I can make the PR and merge (looks like the fork up on your remote repo only has my commits in it).
Wow, I’m excited to see this working!

Here is the related PR https://github.com/mplawley/jhipster-cesium-template/pull/1 :slight_smile:

SUCCESS!!! You did it! Happiness ensues.

This is very awesome. From your changes, it looks like the way to go was to load Cesium globally, which makes sense. I’ll explore why those console errors are appearing, but this is fantastic already. I owe you one, for sure. I was out of ideas with the webpack-cesium issues.

I’m going to try an idea I had with making a service worker for Cesium to load up. But your PR already fixes this issue!

hi,

i’m i need deal with the same problem and i was wonder if you have a recent version of the template, because i download and it seems the version of Cesium package it’s different (because i have some include issues in certain files)

Try this

Maybe its me, but it is frustrating to be sent to a page with multiple files in github.
Which files are pertinent to this particular problem?
Am I the only one who does not want to spend days reviewing other peoples code to find a solution that can be fixed in 1 or 2 files?

My problem is I have a blank page with this ā€œprocess is not definedā€ error in util.js coming up in the debug

Hello @Andrew_Foster,

If you refer to the PR, it was created for a specific problem and may not apply to your particular case. Could you please give more info about the issue that you are facing?

Thanks :smiley:

Thank you for getting back with me.
Yes, I can see how your response, with the github reference, to the post above makes sense.
Also, I apologize for venting on the forum.

I followed the steps in the link below.

Then, following the next link in the tutorial below,

I entered
in app.component.html

And I got a blank white page

I then entered the code below into polyfills.ts

(window as any).global = window;
(window as any).process = {
env: { DEBUG: undefined },
};

Now I get a mostly white page with a very slim map at the top, if I click to expand, I get a black space background with no globe

Also, my assets dir is empty

1 Like

I meant to say

I entered the ac-map tag in app.component.html

The slim map at the top sounds like a CSS styling issue. Maybe you can experiment with the CSS properties of the HTML element with the map-container class?

BTW, do you have any code or GitHub link from the project that you could share? Bear in mind also that angular-cesium is not directly supported from the Cesium team, so I will try to do my best to help you :slightly_smiling_face:

1 Like