You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(window as any).CESIUM_BASE_URL = '/';
import * as Cesium from 'cesium';
import "cesium/Build/Cesium/Widgets/widgets.css";
Cesium.Ion.defaultAccessToken = 'xxxxxxxxx';
@Component({
selector: 'app-cesium-map',
templateUrl: './cesium-map.component.html',
styleUrls: ['./cesium-map.component.css']
})
export class CesiumMapComponent implements OnInit {
constructor() { }
ngOnInit(): void {
const viewer = new Cesium.Viewer('cesiumContainer', {
terrainProvider: Cesium.createWorldTerrain()
});
}
}
but still I have this error:
BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
This is no longer the case. Verify if you need this module and configure a polyfill for it.
If you want to include a polyfill, you need to:
- add a fallback 'resolve.fallback: { "http": require.resolve("stream-http") }'
- install 'stream-http'
If you don't want to include a polyfill, you can use an empty module like this:
resolve.fallback: { "http": false }
Do you know how can I solve this?
Suggestion: I really think the cesiumjs-quickstart page should at least point to a blog page with an updated description of the passages to make cesiumjs work with angular as a module. the infos found work (i think) only for older versions of angular/cesium
The text was updated successfully, but these errors were encountered:
Operating System: Pop! OS 22.04
Angular/CLI version: 14.0.1
@angular-builders/custom-webpack version: 14.0.1
Cesium version: 1.98.1
installed CesiumJS with:
npm install --save-dev cesium
followed instruction taken here:
#8673
and changed angular.json following this:
https://github.com/Developer-Plexscape/cesium-angular-example/blob/master/angular.json
my angular.json:
then added a extra-webpack.config.js file in the root of the project following again this:
https://github.com/Developer-Plexscape/cesium-angular-example/blob/master/extra-webpack.config.js
my webpack extra config:
and added a simple angular module like this:
but still I have this error:
Do you know how can I solve this?
Suggestion: I really think the cesiumjs-quickstart page should at least point to a blog page with an updated description of the passages to make cesiumjs work with angular as a module. the infos found work (i think) only for older versions of angular/cesium
The text was updated successfully, but these errors were encountered: