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

feat: import messages with 2 fewer imports #1003

Merged
merged 1 commit into from
Dec 8, 2023

Conversation

mshanemc
Copy link
Contributor

@mshanemc mshanemc commented Dec 7, 2023

What does this PR do?

simplify loading messageDirs

  • you don't need to import fileURLToPath and path.dirname
import { dirname } from 'node:path'
import { fileURLToPath } from 'node:url'
Messages.importMessagesDirectory(dirname(fileURLToPath(import.meta.url)))

=>

Messages.importMessagesDirectoryFromMetaUrl(import.meta.url)

What issues does this PR fix or reference?

@W-14626332@

roll it out everywhere with salesforcecli/eslint-plugin-sf-plugin#358

@mdonnalley mdonnalley merged commit 8080fc9 into main Dec 8, 2023
69 checks passed
@mdonnalley mdonnalley deleted the sm/messages-import-simplification branch December 8, 2023 20:01
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