Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix pro wasm bug, refactor JS module loading #263

Merged
merged 1 commit into from
Nov 15, 2023
Merged

Conversation

TimPurdum
Copy link
Collaborator

  • Moved all JS Module loading into JsModuleManager static class
  • Changed the order of module loading so that Pro never gets loaded twice
  • Fix the bug, closes Refactor JS Module Loading to fix WASM Sync-JS bug in GeoBlazor Pro #262 , where Pro was not loading the Core JS via the Pro.getCore method. I did this by loading the pro in the JSHost, and then having a duplicated implementation on the JS side of the synchronous method.

@TimPurdum TimPurdum self-assigned this Nov 15, 2023
{
if (ProJsViewModule is not null)
{
AddGraphicsProSyncInterop(graphics, id, layerId);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume the pro code PR will have this method adjustment, since the AddGraphicsCoreSyncInterop is the only method in Core's arcGISJsInterop.ts?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the method didn't actually exist at all in arcGisPro.ts yet, it is added in that PR.

Copy link
Collaborator

@seahro seahro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one comment. Looks good. There have been multiple refactors to switch MapView to View. Will need to keep an eye on that in the other open PRs.

@TimPurdum
Copy link
Collaborator Author

one comment. Looks good. There have been multiple refactors to switch MapView to View. Will need to keep an eye on that in the other open PRs.

This was actually switching from a static method to an instance method. MapView.AddSync... was a static method, so it was on the class type, not on the instance, which was stored as View in Layer.cs.

@TimPurdum TimPurdum merged commit 59a26ad into develop Nov 15, 2023
@TimPurdum TimPurdum deleted the bug/262-pro-wasm branch November 15, 2023 22:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor JS Module Loading to fix WASM Sync-JS bug in GeoBlazor Pro
2 participants