Skip to content
This repository has been archived by the owner on Jul 27, 2021. It is now read-only.

Make the message and note option support function in the compilationSuccessInfo option #97

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Heanes
Copy link

@Heanes Heanes commented Aug 30, 2019

I want the message to output the current time, and after every recompiled, so I need to pass in the function.
Just like this:

new FriendlyErrorsPlugin({
  compilationSuccessInfo: {
    messages: [
      () => `${utils.getFormatDate()}Your application is running here: http://${webpackConfig.devServer.host}:${port}`
    ]
  }
});

After change it, the output will change after every recompiled:
image

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant