Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for title function for dynamic titles #53

Closed
wants to merge 1 commit into from

Conversation

rkoval
Copy link
Contributor

@rkoval rkoval commented Apr 25, 2019

allows you to do something like this to show different titles for different conditions:

return new WebpackNotifierPlugin({
  title({msg}) {
    if (msg.startsWith('Error')) {
      return 'build error ❌';
    } else if (msg.startsWith('Warning')) {
      return 'build warning ⚠️';
    }
    return 'build complete ✅';
  },
});

@rkoval
Copy link
Contributor Author

rkoval commented Apr 25, 2019

related to #48 i think

@Evilart86
Copy link

ty for this feature! its actually what I wanted)

inoyakaigor pushed a commit to inoyakaigor/webpack-notifier-2 that referenced this pull request Dec 10, 2019
inoyakaigor pushed a commit to inoyakaigor/webpack-notifier-2 that referenced this pull request Dec 10, 2019
@Gvozd
Copy link
Collaborator

Gvozd commented Nov 15, 2020

@rkoval
Please rebase PR on current master, and update README.md
After I will merge PR

Gvozd added a commit that referenced this pull request Nov 29, 2020
@Gvozd
Copy link
Collaborator

Gvozd commented Nov 29, 2020

Rebased manually, and updated the documentation
v1.11.0

@Gvozd Gvozd closed this Nov 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants