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

fix: prevent extra leading whitespace in stopAndPersist when symbol i… #243

Merged
merged 1 commit into from
Nov 1, 2024

Conversation

zhanxiaoge
Copy link
Contributor

Summary
When using stopAndPersist with { symbol: '', text: 'text...' }, an extra leading whitespace appears before the text in the terminal.

Example Code

import ora from 'ora';

const spinner = ora().start('Ora Start');

setTimeout(() => {
  spinner.stopAndPersist({ symbol: '', text: 'Ora Stop' });
}, 1000);

@sindresorhus sindresorhus merged commit 5117dfb into sindresorhus:main Nov 1, 2024
3 checks passed
@zhanxiaoge zhanxiaoge deleted the fix/symbol-empty-string branch November 13, 2024 12:53
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.

2 participants