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: add onTarget to template recommendations config #1132

Merged
merged 5 commits into from
Aug 23, 2024

Conversation

dkonieczek
Copy link
Contributor

No description provided.

@dkonieczek dkonieczek linked an issue Aug 14, 2024 that may be closed by this pull request
Copy link
Contributor

@korgon korgon left a comment

Choose a reason for hiding this comment

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

Should we go deeper with the object? or no?

Comment on lines 85 to 99
'recommendation.bundle': {
RecommendationBundle: async () => {
return (
this.components.recommendation.Recommendation ||
(this.components.recommendation.Recommendation = (await import('./library/components/Recommendation')).Recommendation)
this.components['recommendation.bundle'].RecommendationBundle ||
(this.components['recommendation.bundle'].RecommendationBundle = (
await import('./library/components/RecommendationBundle')
).RecommendationBundle)
);
},
RecommendationBundle: async () => {
},
'recommendation.default': {
Recommendation: async () => {
return (
this.components.recommendation.RecommendationBundle ||
(this.components.recommendation.RecommendationBundle = (await import('./library/components/RecommendationBundle')).RecommendationBundle)
this.components['recommendation.default'].Recommendation ||
(this.components['recommendation.default'].Recommendation = (await import('./library/components/Recommendation')).Recommendation)
Copy link
Contributor

Choose a reason for hiding this comment

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

Is there any reason to not actually go another level deeper in the object instead of using a . to delimit the path superficially?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No particular reason. I think I'd actually prefer a / instead of . since we don't do this else where. Nested object would also work

Copy link
Contributor

Choose a reason for hiding this comment

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

Unless there is good reason, I think my preference here is nested object.

@dkonieczek dkonieczek marked this pull request as ready for review August 21, 2024 21:28
@dkonieczek dkonieczek requested a review from korgon August 23, 2024 17:08
@dkonieczek dkonieczek merged commit 550a2d2 into templates Aug 23, 2024
1 check passed
@dkonieczek dkonieczek deleted the TemplateEditor-Recs branch August 23, 2024 17:33
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.

TemplateEditor Recommendations
2 participants