[openstreetmap/openstreetmap-website] Fix all no-implicit-globals eslint errors (PR #5613)
Holger Jeromin
notifications at github.com
Wed Feb 5 18:59:55 UTC 2025
@HolgerJeromin commented on this pull request.
> @@ -1,21 +1,22 @@
-function openShareUrl(url, initialWidth = 640, initialHeight = 480) {
- const width = Math.max(100, Math.min(screen.width, initialWidth));
- const height = Math.max(100, Math.min(screen.height, initialHeight));
+(function () {
+ function openShareUrl(url, initialWidth = 640, initialHeight = 480) {
Perhaps we can use the following pattern. But we have to skip `no-lone-blocks` rule.
```js
// eslint ignore no-lone-blocks
{
function FOSSGISOSRMEngine(id, vehicleType) { ... }
FOSSGISOSRMEngine(...)
}
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5613#discussion_r1943509680
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/5613/review/2596717475 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250205/de1f2595/attachment.htm>
More information about the rails-dev
mailing list