formatjs / formatjs-old

The monorepo home to all of the FormatJS related libraries.
https://formatjs.io/
156 stars 53 forks source link

[intl-messageformat-parser]: Possible breaking change in using pound symbol? #437

Closed cheryly279 closed 4 years ago

cheryly279 commented 4 years ago

Which package? intl-messageformat-parser

Describe the bug Receiving errors like: The intl string context variable "undefined" was not provided to the string "undefined" recently, could that be related to this update? https://github.com/formatjs/formatjs/releases/tag/intl-messageformat-parser%403.6.0

I fixed by updating my messages like:

    title: {
        id: 'blah.blah.blah',
        defaultMessage: `{score, plural, one {# shopper} other {# shoppers}}`,
    },

to

    title: {
        id: 'blah.blah.blah',
        defaultMessage: `{score, plural, one {'#' shopper} other {'#' shoppers}}`,
    },

Was this meant to be a breaking change?

longlho commented 4 years ago

hmm it's not supposed to break. We'll take a look asap

longlho commented 4 years ago

oh seems like a mismatch version cause this issue. If you upgrade intl-messageformat as well that should fix it.

pyrocat101 commented 4 years ago

@longlho Shall we nuke 3.6.2 and release a new major version of intl-messageformat-parser instead?

cheryly279 commented 4 years ago

oh seems like a mismatch version cause this issue. If you upgrade intl-messageformat as well that should fix it.

That worked, thank you!