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(emoji): index emoji data once for search functions #5554

Merged
merged 1 commit into from
May 6, 2024

Conversation

Antreesy
Copy link
Contributor

@Antreesy Antreesy commented May 6, 2024

☑️ Resolves

  • Index emoji 'database' only when first time calling a function (like emojiSearch())
  • Apply method similar to what is used in EmojiPicker

🖼️ Screenshots

Tested with:

	console.time('emoji')
	for (let i = 0; i < N; i ++) {
		const em1 = emojiSearch(text, 10)
	}
	console.timeEnd('emoji')
🏚️ Before (N = 10) 🏚️ Before (N = 1000) 🏡 After (N = 1000)
Screenshot from 2024-05-06 17-53-05 Screenshot from 2024-05-06 17-51-53 Screenshot from 2024-05-06 17-49-27

🏁 Checklist

  • ⛑️ Tests are included or are not applicable
  • 📘 Component documentation has been extended, updated or is not applicable
  • 3️⃣ Backport to next requested with a Vue 3 upgrade

@Antreesy Antreesy added bug Something isn't working 3. to review Waiting for reviews feature: emoji picker Related to the emoji picker component labels May 6, 2024
@Antreesy Antreesy added this to the 8.11.3 milestone May 6, 2024
@Antreesy Antreesy requested review from susnux and ShGKme May 6, 2024 16:02
@Antreesy Antreesy self-assigned this May 6, 2024
Copy link
Contributor

@ShGKme ShGKme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💙

@susnux susnux merged commit 902958b into master May 6, 2024
18 checks passed
@susnux susnux deleted the fix/noid/emoji-index-singleton branch May 6, 2024 16:14
@susnux
Copy link
Contributor

susnux commented May 6, 2024

/backport to next

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug Something isn't working feature: emoji picker Related to the emoji picker component
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants