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

Rename prop style as it is a reserved word #157

Closed
d-koppenhagen opened this issue Mar 28, 2023 · 0 comments
Closed

Rename prop style as it is a reserved word #157

d-koppenhagen opened this issue Mar 28, 2023 · 0 comments

Comments

@d-koppenhagen
Copy link
Collaborator

Is your feature request related to a problem? Please describe.

Some components are using the property style which shouldn't be used as it's a reserved keyword.
Running ESLint with eslint-plugin-vue show the affected components:

/Users/dannykoppenhagen/dev/vue3-openlayers/src/components/interaction/ClusterSelectInteraction.vue
  71:5  error  'style' is a reserved attribute and cannot be used as props  vue/no-reserved-props

/Users/dannykoppenhagen/dev/vue3-openlayers/src/components/layers/VectorLayer.vue
  52:5  error  'style' is a reserved attribute and cannot be used as props  vue/no-reserved-props

/Users/dannykoppenhagen/dev/vue3-openlayers/src/components/layers/WebglPointsLayer.vue
  40:5  error  'style' is a reserved attribute and cannot be used as props  vue/no-reserved-props

/Users/dannykoppenhagen/dev/vue3-openlayers/src/components/sources/SourceWMTS.vue
  140:5  error  'style' is a reserved attribute and cannot be used as props  vue/no-reserved-props

Describe the solution you'd like
The property of each of the affected components should be renamed to e. g. sytles.

  • styles does conflict with the reseved keyword style for an HTML Element.
  • styles can typically be either a Style, an Style[] or a StyleFunction

Describe alternatives you've considered

Additional context
The implementation of this rule showing the reserved keywords can be found here

This will be a breaking change

d-koppenhagen added a commit that referenced this issue Apr 14, 2023
closes #157

BREAKING CHANGE:
The property `style` that has been used for several components has been renamed to `styles` (plural) as it conflicted with the reserved `style` attribute.
The following components are affected:
- `ol-vector-layer`
- `ol-webglpoints-layer`
- `ol-source-wmts`
d-koppenhagen added a commit that referenced this issue Apr 14, 2023
#### [v0.2.0](v0.1.75...v0.2.0)

- refactor: make all provided `styleable`'s a computed [`#178`](#178)
- feat: rename property `style` to `styles` [`#157`](#157)
- docs: add documentation for `ol-interaction-clusterselect` [`#176`](#176)
- chore: package maintenance [`934d428`](934d428)
- docs(a11y): use correct headline levels [`7cdb130`](7cdb130)
- docs: restructure docs [`17c9106`](17c9106)
- feat: remove `imageSmoothing` option from sources [`30cb173`](30cb173)
- feat: provide new options for `ol-interaction-clusterselect` [`86e1a7f`](86e1a7f)
- feat: remove `forEachLayerAtPixel` method from `ol-map` [`78d94bd`](78d94bd)
- fix(ol-interaction-clusterselect): remove unsupported prop `style` [`065a6e8`](065a6e8)
- feat: remove `undefinedHTML` option from control `ol-mouse-position` [`debd387`](debd387)
- chore: update PR template [`30b6621`](30b6621)
- docs: set minimum openlayers version to 7.3.0 [`7974a65`](7974a65)
- chore: update PR template [`5020ff4`](5020ff4)
- fix(MapControls) - added missing RotateControl export [`00201c9`](00201c9)
justinbedia pushed a commit to justinbedia/openLayers that referenced this issue Sep 29, 2023
#### [v0.2.0](MelihAltintas/vue3-openlayers@v0.1.75...v0.2.0)

- refactor: make all provided `styleable`'s a computed [`#178`](MelihAltintas/vue3-openlayers#178)
- feat: rename property `style` to `styles` [`#157`](MelihAltintas/vue3-openlayers#157)
- docs: add documentation for `ol-interaction-clusterselect` [`#176`](MelihAltintas/vue3-openlayers#176)
- chore: package maintenance [`934d428`](MelihAltintas/vue3-openlayers@934d428)
- docs(a11y): use correct headline levels [`7cdb130`](MelihAltintas/vue3-openlayers@7cdb130)
- docs: restructure docs [`17c9106`](MelihAltintas/vue3-openlayers@17c9106)
- feat: remove `imageSmoothing` option from sources [`30cb173`](MelihAltintas/vue3-openlayers@30cb173)
- feat: provide new options for `ol-interaction-clusterselect` [`86e1a7f`](MelihAltintas/vue3-openlayers@86e1a7f)
- feat: remove `forEachLayerAtPixel` method from `ol-map` [`78d94bd`](MelihAltintas/vue3-openlayers@78d94bd)
- fix(ol-interaction-clusterselect): remove unsupported prop `style` [`065a6e8`](MelihAltintas/vue3-openlayers@065a6e8)
- feat: remove `undefinedHTML` option from control `ol-mouse-position` [`debd387`](MelihAltintas/vue3-openlayers@debd387)
- chore: update PR template [`30b6621`](MelihAltintas/vue3-openlayers@30b6621)
- docs: set minimum openlayers version to 7.3.0 [`7974a65`](MelihAltintas/vue3-openlayers@7974a65)
- chore: update PR template [`5020ff4`](MelihAltintas/vue3-openlayers@5020ff4)
- fix(MapControls) - added missing RotateControl export [`00201c9`](MelihAltintas/vue3-openlayers@00201c9)
BlueSky428 added a commit to BlueSky428/Vue3-Openlayers that referenced this issue May 19, 2024
#### [v0.2.0](MelihAltintas/vue3-openlayers@v0.1.75...v0.2.0)

- refactor: make all provided `styleable`'s a computed [`#178`](MelihAltintas/vue3-openlayers#178)
- feat: rename property `style` to `styles` [`#157`](MelihAltintas/vue3-openlayers#157)
- docs: add documentation for `ol-interaction-clusterselect` [`#176`](MelihAltintas/vue3-openlayers#176)
- chore: package maintenance [`934d428`](MelihAltintas/vue3-openlayers@934d428)
- docs(a11y): use correct headline levels [`7cdb130`](MelihAltintas/vue3-openlayers@7cdb130)
- docs: restructure docs [`17c9106`](MelihAltintas/vue3-openlayers@17c9106)
- feat: remove `imageSmoothing` option from sources [`30cb173`](MelihAltintas/vue3-openlayers@30cb173)
- feat: provide new options for `ol-interaction-clusterselect` [`86e1a7f`](MelihAltintas/vue3-openlayers@86e1a7f)
- feat: remove `forEachLayerAtPixel` method from `ol-map` [`78d94bd`](MelihAltintas/vue3-openlayers@78d94bd)
- fix(ol-interaction-clusterselect): remove unsupported prop `style` [`065a6e8`](MelihAltintas/vue3-openlayers@065a6e8)
- feat: remove `undefinedHTML` option from control `ol-mouse-position` [`debd387`](MelihAltintas/vue3-openlayers@debd387)
- chore: update PR template [`30b6621`](MelihAltintas/vue3-openlayers@30b6621)
- docs: set minimum openlayers version to 7.3.0 [`7974a65`](MelihAltintas/vue3-openlayers@7974a65)
- chore: update PR template [`5020ff4`](MelihAltintas/vue3-openlayers@5020ff4)
- fix(MapControls) - added missing RotateControl export [`00201c9`](MelihAltintas/vue3-openlayers@00201c9)
smart-tech-guru added a commit to smart-tech-guru/vue-openlayers that referenced this issue Jun 3, 2024
#### [v0.2.0](MelihAltintas/vue3-openlayers@v0.1.75...v0.2.0)

- refactor: make all provided `styleable`'s a computed [`#178`](MelihAltintas/vue3-openlayers#178)
- feat: rename property `style` to `styles` [`#157`](MelihAltintas/vue3-openlayers#157)
- docs: add documentation for `ol-interaction-clusterselect` [`#176`](MelihAltintas/vue3-openlayers#176)
- chore: package maintenance [`934d428`](MelihAltintas/vue3-openlayers@934d428)
- docs(a11y): use correct headline levels [`7cdb130`](MelihAltintas/vue3-openlayers@7cdb130)
- docs: restructure docs [`17c9106`](MelihAltintas/vue3-openlayers@17c9106)
- feat: remove `imageSmoothing` option from sources [`30cb173`](MelihAltintas/vue3-openlayers@30cb173)
- feat: provide new options for `ol-interaction-clusterselect` [`86e1a7f`](MelihAltintas/vue3-openlayers@86e1a7f)
- feat: remove `forEachLayerAtPixel` method from `ol-map` [`78d94bd`](MelihAltintas/vue3-openlayers@78d94bd)
- fix(ol-interaction-clusterselect): remove unsupported prop `style` [`065a6e8`](MelihAltintas/vue3-openlayers@065a6e8)
- feat: remove `undefinedHTML` option from control `ol-mouse-position` [`debd387`](MelihAltintas/vue3-openlayers@debd387)
- chore: update PR template [`30b6621`](MelihAltintas/vue3-openlayers@30b6621)
- docs: set minimum openlayers version to 7.3.0 [`7974a65`](MelihAltintas/vue3-openlayers@7974a65)
- chore: update PR template [`5020ff4`](MelihAltintas/vue3-openlayers@5020ff4)
- fix(MapControls) - added missing RotateControl export [`00201c9`](MelihAltintas/vue3-openlayers@00201c9)
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

No branches or pull requests

1 participant