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

Feature/add l tile layer wms #50

Merged

Conversation

mo-martinwilson
Copy link
Contributor

@mo-martinwilson mo-martinwilson commented Oct 30, 2024

This is a PR that addresses 3/4 requirements from Issue 45: Add WMS Layer Support.

  • Use light DOM in accordance with existing Custom Elements.
  • Support non-WMS query parameters by leveraging the underlying L.TileLayer.WMS options object
  • Add unit tests to cover lifecycle events
  • Add API docs to instruct users to use attributes correctly

attribution: optional(htmlAttribute("attribution")),

// Optional options
options: optional(htmlAttribute("options")),
Copy link
Owner

Choose a reason for hiding this comment

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

I think this needs to be JSON parsed and merged with the other wmsOptions object. At least, that's my understanding from the Leaflet WMS docs

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah great point. Addressed in 5756053

…g, and parse accordingly. Also written tests and formatted.
"Error whilst parsing JSON for options attribute in l-tile-layer-wms",
e,
);
return null;
Copy link
Owner

Choose a reason for hiding this comment

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

How does this behave with ... destructuring?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

great point, addressed in two commits:

Copy link
Owner

@andrewgryan andrewgryan left a comment

Choose a reason for hiding this comment

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

A highly useful addition to the library!

@andrewgryan andrewgryan merged commit f1ed7ea into andrewgryan:master Oct 30, 2024
1 check passed
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.

2 participants