lit-translate
lit-translate copied to clipboard
Feature request: Upgrade to lit-html 2.0
...using new Directive class :-)
@andreasbm - just interested to know if this is somehow in a tentative pipeline, now that lit 2.0 is at release candidate stage ?
Thanks a lot, even if the answer is no!
P.S. I am aware that lit now offers localization (https://lit.dev/docs/libraries/localization/), but I prefer lit-translate
approach allowing to handle localization files in JSON.
I'm super excited about the new Directive class! 🌞 I plan on upgrading the library to lit v2 during the next weekend 👍
Oh, that is great - indeed, lit 2 all together is super exciting !
👍 Thank you. Looking forward to the release.
I have now released lit-translate with lit 2 as a release candidate 👍 You can install it with npm i lit-translate@next
- when lit 2 is officially released I will release this version as well 🌞
Greeat !!! i'm excite for this new version
@andreasbm any updates when this will be a stable release? lit 2 is official now
Hi @andreasbm any change you could do official 2.0.0 release with the lit v2 branch at some point. I'm getting this warning from webpack duplicate detection plugin.
WARNING in lit
Multiple versions of lit found:
2.0.0-rc.2 ./~/lit-translate/~/lit
2.1.2 ./~/lit
Looks like that branch has dep to "latest" lit. But at the time when you did [email protected]
i guess that was [email protected]
.
The package-lock.json
also in that branch has the [email protected]
reference.
I'm not too familiar with npm publishing but i would recond you reinstall latest lit so package-lock.json gets fixed to 2.x.x when make official 2.0.0 npm release for lit-translate.
Edit: App build looks to work fine. I think the downside of this is the app is loading lit two times. Once for lit translate and once for everything else. So even if not causing issues it bloats the build unnecessarily.
using npm v8 here is relevant part from my apps lock file
"node_modules/lit-translate": {
"version": "2.0.0-rc.1",
"resolved": "https://registry.npmjs.org/lit-translate/-/lit-translate-2.0.0-rc.1.tgz",
"integrity": "sha512-8r7MK4OuFoUis41RHS4pFxIuCKn8K/nBdhJKdcnCeD+2MEH0Wg2oiaodYxK6cYcyzc0dFGf1+a/32r4Ym7A/cg==",
"dependencies": {
"lit": "2.0.0-rc.2"
}
},
"node_modules/lit-translate/node_modules/lit": {
"version": "2.0.0-rc.2",
"resolved": "https://registry.npmjs.org/lit/-/lit-2.0.0-rc.2.tgz",
"integrity": "sha512-BOCuoJR04WaTV8UqTKk09cNcQA10Aq2LCcBOiHuF7TzWH5RNDsbCBP5QM9sLBSotGTXbDug/gFO08jq6TbyEtw==",
"dependencies": {
"@lit/reactive-element": "^1.0.0-rc.2",
"lit-element": "^3.0.0-rc.2",
"lit-html": "^2.0.0-rc.3"
}
},
@andreasbm Would you be interested in allowing others to help with the maintenance of this library?
Shouldn't this issue be closed? I somehow stumbled over this and thought lit-translate would still be on v1 but then fortunately noticed in the releases section that v2 is already out :-)