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: Adds a new metadata bundle type for AppFrameworkTemplates #1442

Merged

Conversation

rvwatch
Copy link
Contributor

@rvwatch rvwatch commented Oct 25, 2024

What does this PR do?

Adds a new metadata bundle type for AppFrameworkTemplates.

What issues does this PR fix or reference?

@W-16928554@

#, @@

Functionality Before

CLI no have AppFrameworkTemplates metadata
<insert gif and/or summary>

Functionality After

CLI now have AppFrameworkTemplates metadata!
<insert gif and/or summary>

@rvwatch rvwatch requested a review from a team as a code owner October 25, 2024 20:58
Copy link

Thanks for the contribution! It looks like @rvwatch is an internal user so signing the CLA is not required. However, we need to confirm this.

@@ -4639,6 +4644,49 @@
"directoryName": "extlClntAppPushPolicies",
"inFolder": false,
"strictDirectoryName": false
},
"appframeworktemplatebundle": {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I only added this guy. Scripts added the rest.

@@ -112,17 +112,26 @@ export const filePathsFromMetadataComponent = (

// lwc, aura, waveTemplate, experiencePropertyType
if (type.strategies?.adapter === 'bundle') {
const mappings = new Map<string, string>([
const mappings = new Map<string, string | string[]>([
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I didn't want to mess around with the other bundles, so the only way I could get this to accept my new bundle and still pass the tests was to add the or string[].

const matched = mappings.get(type.name);
if (!matched) {
throw messages.createError('unsupportedBundleType', [type.name]);
}
return [matched];

return Array.isArray(matched) ? matched : [matched];
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Dealing with my array of strings or strings situation.

@WillieRuemmele WillieRuemmele mentioned this pull request Oct 25, 2024
@WillieRuemmele WillieRuemmele merged commit 699cf7a into forcedotcom:main Oct 28, 2024
61 of 76 checks passed
@rvwatch rvwatch deleted the rv/add-appframeworktemplatebundle branch October 29, 2024 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants