Skip to content

[React Intl] Could not find required intl object. <IntlProvider> needs to exist in the component ancestry. #351

@781574155

Description

@781574155

当使用umi max的国际化时,如果用KeepAlive标签包裹会报错:

export default () => (
  <KeepAlive saveScrollPosition="screen" name="/file-manage:谛听">
    <Page />
  </KeepAlive>
);

如果不用KeepAlive,正常显示:

export default () => (
    <Page />
);

此外,使用KeepAlive后,useModel('@@initialState');也使用不了

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions