Closed
Description
I'm working on Vue.js library for fluent.js and wanted to add functionality to split localization into multiple bundles. But I want to be able to share commonly used messages and terms across bundles. Here is simple implementation of a bundle that has this functionality:
https://github.com/Demivan/fluent-vue/blob/7cdd3932130a76b7b270c1113860fb3a3fc8c30f/packages/fluent-vue/src/extendedFluentBundle.ts
This is pretty mush all of it:
getMessage(id: string): Message | undefined {
return this._messages.get(id) || this.parent.getMessage(id)
}
Problem with it is that child bundle cannot reference parent terms or messages because resolver does not call getMessage
method but is accessing _messages
directly:
fluent.js/fluent-bundle/src/resolver.ts
Line 205 in f41d910
Can something like this e07d6f7 be added so it is possible to implement this functionality?
Or maybe there is other way of sharing messages and terms?
Metadata
Metadata
Assignees
Labels
No labels