[openstreetmap/openstreetmap-website] Add eslint-plugin-erb to provide linting of our .js.erb files (PR #5549)

Andy Allan notifications at github.com
Fri Jan 24 14:46:03 UTC 2025


Fixes #5523 

This is a draft, since our .js.erb files don't currently pass the linting. I've fixed the straightforward ones in #5548 but there are a few more to complete before this can be merged.

I've opened this pull request to make it easier for other developers (who have more JS skills) to help. My recommendation is to checkout this pull request locally, fix the errors, and submit those fixes separately as PRs (e.g. cherry-pick your fixes onto our master branch).
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/5549

-- Commit Summary --

  * Fix some eslint errors (quotes, spacing and parseInt radix) on .js.erb files
  * Add eslint-plugin-erb to provide linting of our .js.erb files

-- File Changes --

    M app/assets/javascripts/edit/id.js.erb (6)
    M app/assets/javascripts/embed.js.erb (36)
    M app/assets/javascripts/osm.js.erb (85)
    M config/eslint.js (11)
    M lib/tasks/eslint.rake (2)
    M package.json (1)
    M yarn.lock (5)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/5549.patch
https://github.com/openstreetmap/openstreetmap-website/pull/5549.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/5549
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/5549 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20250124/0716ca8c/attachment-0001.htm>


More information about the rails-dev mailing list