Skip to content

[WIP] Modernise ember-leaflet #704

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

Closed

Conversation

- Modernisation attempts
- @ember/string v3 causes a lot of pain
- ember-auto-import needs bump
- Why not bring leaflet directly?
- I believe v6 should work here
- Needed for ensuresafecomponent
- v18 should be reasonably adopted by now
# Conflicts:
#	.github/workflows/ci.yml
#	CONTRIBUTING.md
#	README.md
#	ember-cli-build.js
#	index.js
#	tests/dummy/app/config/environment.d.ts
#	tests/dummy/config/ember-try.js
#	tests/helpers/index.js
#	tsconfig.json
#	types/global.d.ts
- name: Run Tests
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }}

deploy-app:
Copy link
Owner

Choose a reason for hiding this comment

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

We shouldn't remove the deploy-app job.

Copy link
Owner

Choose a reason for hiding this comment

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

Not sure what this file is, but probably we shouldn't include files for very specific tools.

Copy link
Owner

Choose a reason for hiding this comment

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

This change completely removes everything that is interesting about the current README. Please restore the readme. 🙏

faviconsConfig: {
path: '/ADDON_DOCS_ROOT_URL'
}
}
Copy link
Owner

Choose a reason for hiding this comment

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

I don't think we should remove the fingerprint and ember-cli-favicon options. These are important for the docs app.


pathBase(packageName) {
return path.dirname(resolve.sync(packageName + '/package.json', { basedir: __dirname }));
}
};
Copy link
Owner

Choose a reason for hiding this comment

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

This is a big change. I understand that import Leaflet from 'leaflet'; will take care of importing the js.
But what about the css and images? What is importing them now?

"ember-in-element-polyfill": "^1.0.0",
"ember-render-helpers": "^0.2.0",
"fastboot-transform": "^0.1.3",
"leaflet": "^1.9.2",
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 leaflet should be kept as a peerDependency + devDependency.
This way, the consuming app will be able to determine what leaflet version they use.

Copy link
Owner

Choose a reason for hiding this comment

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

My question is why do we have typescript related things? Are we able to start writing TS with this?

@MichalBryxi MichalBryxi changed the title Modernise ember-leaflet [WIP] Modernise ember-leaflet Apr 23, 2025
@MichalBryxi
Copy link
Author

🙇🏾 Thanks for your attention @miguelcobain. I am experimenting with multiple approaches now (this branch and v2 so far) and trying to land the most annoying fixes for ember-cli-addon-docs (1, 2, 3) which should remove a lot of the hacks here.

This PR should've been marked as [WIP] from the start.

@MichalBryxi
Copy link
Author

And branch that contains relatively minimal amount of changes (but still needs ember-cli-addon-docs fixes from above): https://github.com/MichalBryxi/ember-leaflet/tree/mb/hotfixes-from-abefordisc-3

@MichalBryxi
Copy link
Author

I think this branch contains way better and less intrusive changes: #705 and should be used instead. Sorry for the noise.

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