The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.
Every fusionCore package follows the same coding conventions so the codebase stays consistent, performant, and reviewable across teams. This page collects those rules. Read it alongside fusionSpan’s common coding standards in Confluence, which cover the general guidance for working with code at fusionSpan; the rules below add the fusionCore-specific expectations on top of that baseline.
Keep Your Code Clean
Before you commit, tidy up the changeset:
Remove unused code.
Remove commented-out code.
Remove debug statements.
Make Your Code Review-Ready
Work through this checklist before you submit a change for review:
Record a short video of the feature showing the intended use case.
Post a list of the positive and negative tests you ran for the feature on the ticket.
Make sure the code is performant. It should be bulkified, use Set, Map, and other data structures to reduce CPU time, and minimize heap and database load through cache methods and carefully crafted SOQL.
Run PMD checks and make sure they pass. The current rulesets live in the pmd-rulesets repo in Bitbucket.
Run all unit tests and make sure they pass.
Match the Metadata API Version
Match the API version of any metadata you create to the sourceApiVersion field in the package’s sfdx-project.json, for example "sourceApiVersion": "65.0". In almost all cases your code should match this value.
Do not bump sourceApiVersion without talking to the package owner. Older packages may sit on an older version on purpose, and the team usually updates all of a class’s metadata at the same time. Some packages are older than others, so the value differs from package to package.
How you name metadata depends on whether the package is managed or unmanaged. You can tell which a package is from the namespace field in its sfdx-project.json: a populated namespace string means the package is managed, while an empty or missing namespace means it is unmanaged.
Unmanaged Packages
Metadata in an unmanaged package carries a per-package prefix, for example FC_EG_MyApexClass or FC_EG_MyObject__c. Find the prefix for a given package near the top of its README.md, under the Development Conventions section.
Managed Packages
Do not add a prefix to metadata in a managed package — Salesforce adds the namespace automatically. There is one exception:
Record types — prefix the API Name (DeveloperName) with FC_. For example, a record type with the label Miscellaneous has the API name FC_Miscellaneous.
If you add formula fields, or links to pages, inside a managed package, include the namespace where appropriate.
Place Layouts and FlexiPages in the Layouts Package
Put layout and FlexiPage changes in the Layouts package rather than in a managed package. Managed-package layouts are not updatable in client orgs, so a layout shipped inside a managed package cannot be changed after install. The Layouts package is unmanaged, which means its layouts remain editable. Implementers should make copies of these layouts to avoid upgrade issues.
Use Custom Labels Instead of Hardcoded Text
Wherever you display hardcoded text, create a Custom Label for it instead. Set the label’s protected field to false so the implementation team and admins can modify it, and add the appropriate package prefix.
Rules at a Glance
Rule
Notes
Review fusionSpan’s common coding standards
General guidance for working with code at fusionSpan; see the common coding standards in Confluence.
Keep code clean
Remove unused code, commented-out code, and debug statements before committing.
Make code review-ready
Record a demo video, post positive and negative tests on the ticket, confirm performance (bulkified, Set/Map, minimal heap and DB load), pass PMD checks, pass all unit tests.
Match the metadata API version
Match sourceApiVersion in sfdx-project.json; do not bump it without the package owner.
Use the built-in infrastructure
Utility functions, trigger framework, event framework, and services.
Prefer validation trigger units over Validation Rules
Gives you ordering and programmatic disable. If you do add a declarative Validation Rule, gate it on Global_Validations_Enabled__c. See Validation Triggers.
Name unmanaged-package metadata
Apply the per-package prefix (e.g. FC_EG_) documented in the package’s README.md.
Name managed-package metadata
No prefix (the namespace is automatic); prefix record type API Names with FC_.
Place layouts and FlexiPages in the Layouts package
Managed-package layouts are not updatable in client orgs; the Layouts package is unmanaged.
Use Custom Labels for text
Replace hardcoded text with a Custom Label; set protected to false and add the package prefix.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"fusionCore Documentation","colors":{"primary":"#1C80B7","light":"#3FA5DC","dark":"#233862"},"logo":{"light":"https://mintcdn.com/fusionspan/YOJThutruL_JRsTc/logo/fusioncore-light.png?fit=max\u0026auto=format\u0026n=YOJThutruL_JRsTc\u0026q=85\u0026s=214aa6cf854bb355a6f04da3ddfb0d60","dark":"https://mintcdn.com/fusionspan/YOJThutruL_JRsTc/logo/fusioncore-dark.png?fit=max\u0026auto=format\u0026n=YOJThutruL_JRsTc\u0026q=85\u0026s=5fe44ccf31da1e75598fe04552459508"},"favicon":"https://mintcdn.com/fusionspan/EW_gg4_8FJ-921wF/favicon.png?fit=max\u0026auto=format\u0026n=EW_gg4_8FJ-921wF\u0026q=85\u0026s=bdfc3e35ed633844441de878cb99f125","navbar":{"links":[{"href":"mailto:fcsupport@fusionspan.com","label":"Support"}]},"footer":{"socials":{}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"fusionspan","hasAudioNarration":false,"actualSubdomain":"fusionspan","customDomains":["docs.fusioncore.us"],"gitSource":{"type":"github","owner":"fusionspan-llc","repo":"fusioncore-documentation","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":false},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ae22a0e12cf5a20bf490096","clientVersion":"0.0.4344","searchFilterCounts":[{"language":"default","tag":"End User Guides","count":187},{"language":"default","tag":"Accounting","count":44},{"language":"default","tag":"Orders and Opportunities","count":39},{"language":"default","tag":"Portal","count":31},{"language":"default","tag":"Product","count":28},{"language":"default","tag":"Orders","count":14},{"language":"default","tag":"Stripe","count":14},{"language":"default","tag":"Subscriptions","count":14},{"language":"default","tag":"Accelerators","count":13},{"language":"default","tag":"API Reference","count":11}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true,"deflection":{"enabled":true,"email":"fcsupport@fusionspan.com"}},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"site-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"starterQuestions":[],"googleFontsInlined":false},"customCss":[]}
{"page":{"pagePath":"developer-guide/coding-standards","slug":"/developer-guide/coding-standards","pageMetadata":{"title":"Coding Standards","description":"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.","href":"/developer-guide/coding-standards"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Heading,Table,Warning}=_components;if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Every fusionCore package follows the same coding conventions so the codebase stays consistent, performant, and reviewable across teams. This page collects those rules. Read it alongside fusionSpan’s common coding standards in Confluence, which cover the general guidance for working with code at fusionSpan; the rules below add the fusionCore-specific expectations on top of that baseline.`}),`\n`,_jsx(Heading,{level:`2`,id:`keep-your-code-clean`,children:`Keep Your Code Clean`}),`\n`,_jsx(_components.p,{children:`Before you commit, tidy up the changeset:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Remove unused code.`}),`\n`,_jsx(_components.li,{children:`Remove commented-out code.`}),`\n`,_jsx(_components.li,{children:`Remove debug statements.`}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`make-your-code-review-ready`,children:`Make Your Code Review-Ready`}),`\n`,_jsx(_components.p,{children:`Work through this checklist before you submit a change for review:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Record a short video of the feature showing the intended use case.`}),`\n`,_jsx(_components.li,{children:`Post a list of the positive and negative tests you ran for the feature on the ticket.`}),`\n`,_jsxs(_components.li,{children:[`Make sure the code is performant. It should be bulkified, use `,_jsx(_components.code,{children:`Set`}),`, `,_jsx(_components.code,{children:`Map`}),`, and other data structures to reduce CPU time, and minimize heap and database load through cache methods and carefully crafted SOQL.`]}),`\n`,_jsxs(_components.li,{children:[`Run PMD checks and make sure they pass. The current rulesets live in the `,_jsx(_components.code,{children:`pmd-rulesets`}),` repo in Bitbucket.`]}),`\n`,_jsx(_components.li,{children:`Run all unit tests and make sure they pass.`}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`match-the-metadata-api-version`,children:`Match the Metadata API Version`}),`\n`,_jsxs(_components.p,{children:[`Match the API version of any metadata you create to the `,_jsx(_components.code,{children:`sourceApiVersion`}),` field in the package’s `,_jsx(_components.code,{children:`sfdx-project.json`}),`, for example `,_jsx(_components.code,{children:`\"sourceApiVersion\": \"65.0\"`}),`. In almost all cases your code should match this value.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`Do not bump `,_jsx(_components.code,{children:`sourceApiVersion`}),` without talking to the package owner. Older packages may sit on an older version on purpose, and the team usually updates all of a class’s metadata at the same time. Some packages are older than others, so the value differs from package to package.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`use-the-built-in-infrastructure`,children:`Use the Built-In Infrastructure`}),`\n`,_jsxs(_components.p,{children:[`Build on the shared platform infrastructure instead of reinventing it. Reach for the `,_jsx(_components.a,{href:`/developer-guide/utility-functions`,children:`utility functions`}),`, the `,_jsx(_components.a,{href:`/developer-guide/trigger-framework`,children:`trigger framework`}),`, the `,_jsx(_components.a,{href:`/developer-guide/event-framework`,children:`event framework`}),`, and the `,_jsx(_components.a,{href:`/developer-guide/services`,children:`services`}),` before writing your own equivalents.`]}),`\n`,_jsx(Heading,{level:`2`,id:`name-metadata-correctly`,children:`Name Metadata Correctly`}),`\n`,_jsxs(_components.p,{children:[`How you name metadata depends on whether the package is managed or unmanaged. You can tell which a package is from the `,_jsx(_components.code,{children:`namespace`}),` field in its `,_jsx(_components.code,{children:`sfdx-project.json`}),`: a populated `,_jsx(_components.code,{children:`namespace`}),` string means the package is managed, while an empty or missing `,_jsx(_components.code,{children:`namespace`}),` means it is unmanaged.`]}),`\n`,_jsx(Heading,{level:`3`,id:`unmanaged-packages`,children:`Unmanaged Packages`}),`\n`,_jsxs(_components.p,{children:[`Metadata in an unmanaged package carries a per-package prefix, for example `,_jsx(_components.code,{children:`FC_EG_MyApexClass`}),` or `,_jsx(_components.code,{children:`FC_EG_MyObject__c`}),`. Find the prefix for a given package near the top of its `,_jsx(_components.code,{children:`README.md`}),`, under the `,_jsx(_components.strong,{children:`Development Conventions`}),` section.`]}),`\n`,_jsx(Heading,{level:`3`,id:`managed-packages`,children:`Managed Packages`}),`\n`,_jsx(_components.p,{children:`Do not add a prefix to metadata in a managed package — Salesforce adds the namespace automatically. There is one exception:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Record types`}),` — prefix the API Name (`,_jsx(_components.code,{children:`DeveloperName`}),`) with `,_jsx(_components.code,{children:`FC_`}),`. For example, a record type with the label `,_jsx(_components.code,{children:`Miscellaneous`}),` has the API name `,_jsx(_components.code,{children:`FC_Miscellaneous`}),`.`]}),`\n`]}),`\n`,_jsx(_components.p,{children:`If you add formula fields, or links to pages, inside a managed package, include the namespace where appropriate.`}),`\n`,_jsx(Heading,{level:`2`,id:`place-layouts-and-flexipages-in-the-layouts-package`,children:`Place Layouts and FlexiPages in the Layouts Package`}),`\n`,_jsx(_components.p,{children:`Put layout and FlexiPage changes in the Layouts package rather than in a managed package. Managed-package layouts are not updatable in client orgs, so a layout shipped inside a managed package cannot be changed after install. The Layouts package is unmanaged, which means its layouts remain editable. Implementers should make copies of these layouts to avoid upgrade issues.`}),`\n`,_jsx(Heading,{level:`2`,id:`use-custom-labels-instead-of-hardcoded-text`,children:`Use Custom Labels Instead of Hardcoded Text`}),`\n`,_jsxs(_components.p,{children:[`Wherever you display hardcoded text, create a Custom Label for it instead. Set the label’s `,_jsx(_components.code,{children:`protected`}),` field to `,_jsx(_components.code,{children:`false`}),` so the implementation team and admins can modify it, and add the appropriate package prefix.`]}),`\n`,_jsx(Heading,{level:`2`,id:`rules-at-a-glance`,children:`Rules at a Glance`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Rule`}),_jsx(_components.th,{children:`Notes`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Review fusionSpan’s common coding standards`}),_jsx(_components.td,{children:`General guidance for working with code at fusionSpan; see the common coding standards in Confluence.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Keep code clean`}),_jsx(_components.td,{children:`Remove unused code, commented-out code, and debug statements before committing.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Make code review-ready`}),_jsxs(_components.td,{children:[`Record a demo video, post positive and negative tests on the ticket, confirm performance (bulkified, `,_jsx(_components.code,{children:`Set`}),`/`,_jsx(_components.code,{children:`Map`}),`, minimal heap and DB load), pass PMD checks, pass all unit tests.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Match the metadata API version`}),_jsxs(_components.td,{children:[`Match `,_jsx(_components.code,{children:`sourceApiVersion`}),` in `,_jsx(_components.code,{children:`sfdx-project.json`}),`; do not bump it without the package owner.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Use the built-in infrastructure`}),_jsx(_components.td,{children:`Utility functions, trigger framework, event framework, and services.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Prefer validation trigger units over Validation Rules`}),_jsxs(_components.td,{children:[`Gives you ordering and programmatic disable. If you do add a declarative Validation Rule, gate it on `,_jsx(_components.code,{children:`Global_Validations_Enabled__c`}),`. See `,_jsx(_components.a,{href:`/developer-guide/trigger-framework#validation-triggers`,children:`Validation Triggers`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Name unmanaged-package metadata`}),_jsxs(_components.td,{children:[`Apply the per-package prefix (e.g. `,_jsx(_components.code,{children:`FC_EG_`}),`) documented in the package’s `,_jsx(_components.code,{children:`README.md`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Name managed-package metadata`}),_jsxs(_components.td,{children:[`No prefix (the namespace is automatic); prefix record type API Names with `,_jsx(_components.code,{children:`FC_`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Place layouts and FlexiPages in the Layouts package`}),_jsx(_components.td,{children:`Managed-package layouts are not updatable in client orgs; the Layouts package is unmanaged.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Use Custom Labels for text`}),_jsxs(_components.td,{children:[`Replace hardcoded text with a Custom Label; set `,_jsx(_components.code,{children:`protected`}),` to `,_jsx(_components.code,{children:`false`}),` and add the package prefix.`]})]})]})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Coding Standards","description":"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.","href":"/developer-guide/coding-standards"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Keep Your Code Clean","slug":"keep-your-code-clean","depth":2,"children":[]},{"title":"Make Your Code Review-Ready","slug":"make-your-code-review-ready","depth":2,"children":[]},{"title":"Match the Metadata API Version","slug":"match-the-metadata-api-version","depth":2,"children":[]},{"title":"Use the Built-In Infrastructure","slug":"use-the-built-in-infrastructure","depth":2,"children":[]},{"title":"Name Metadata Correctly","slug":"name-metadata-correctly","depth":2,"children":[{"title":"Unmanaged Packages","slug":"unmanaged-packages","depth":3,"children":[]},{"title":"Managed Packages","slug":"managed-packages","depth":3,"children":[]}]},{"title":"Place Layouts and FlexiPages in the Layouts Package","slug":"place-layouts-and-flexipages-in-the-layouts-package","depth":2,"children":[]},{"title":"Use Custom Labels Instead of Hardcoded Text","slug":"use-custom-labels-instead-of-hardcoded-text","depth":2,"children":[]},{"title":"Rules at a Glance","slug":"rules-at-a-glance","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"fusionspan","siteName":"fusionCore Documentation","title":"Coding Standards - fusionCore Documentation","contextualStarterQuestions":[],"navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-07-09T17:43:31.180Z","originalFileLocation":"developer-guide/coding-standards.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\">\u003cmeta data-mint-head name=\"application-name\" content=\"fusionCore Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Coding Standards - fusionCore Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"fusionCore Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.fusioncore.us/developer-guide/coding-standards\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://fusionspan.mintlify.site/_mintlify/api/og/v2?division=Developer+Guide\u0026amp;title=Coding+Standards\u0026amp;description=The+coding+conventions+every+fusionCore+contributor+follows%3A+clean+code%2C+review+readiness%2C+API+versions%2C+and+metadata+naming+for+managed+and+unmanaged+packages.\u0026amp;theme=d675e95a068684c48cb57395\u0026amp;signature=1b68384b1035f4775c1bde32aa7c053f20c156326036b5aeb06748d725dadcaf\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Coding Standards - fusionCore Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://fusionspan.mintlify.site/_mintlify/api/og/v2?division=Developer+Guide\u0026amp;title=Coding+Standards\u0026amp;description=The+coding+conventions+every+fusionCore+contributor+follows%3A+clean+code%2C+review+readiness%2C+API+versions%2C+and+metadata+naming+for+managed+and+unmanaged+packages.\u0026amp;theme=d675e95a068684c48cb57395\u0026amp;signature=1b68384b1035f4775c1bde32aa7c053f20c156326036b5aeb06748d725dadcaf\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/fusionspan/KBKUhZpgwYvCX7Wu/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"fusionCore Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#1C80B7\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.fusioncore.us/developer-guide/coding-standards\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/developer-guide/coding-standards.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.fusioncore.us/#organization\",\"name\":\"fusionCore Documentation\",\"url\":\"https://docs.fusioncore.us\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/fusionspan/YOJThutruL_JRsTc/logo/fusioncore-light.png?fit=max\u0026auto=format\u0026n=YOJThutruL_JRsTc\u0026q=85\u0026s=214aa6cf854bb355a6f04da3ddfb0d60\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.fusioncore.us#website\",\"name\":\"fusionCore Documentation\",\"url\":\"https://docs.fusioncore.us\",\"publisher\":{\"@id\":\"https://docs.fusioncore.us/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.fusioncore.us/developer-guide/coding-standards#webpage\",\"url\":\"https://docs.fusioncore.us/developer-guide/coding-standards\",\"name\":\"Coding Standards\",\"description\":\"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\",\"dateModified\":\"2026-07-09T17:43:31.180Z\",\"isPartOf\":{\"@id\":\"https://docs.fusioncore.us#website\"},\"breadcrumb\":{\"@id\":\"https://docs.fusioncore.us/developer-guide/coding-standards#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.fusioncore.us/developer-guide/coding-standards#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Developer Guide\",\"item\":\"https://docs.fusioncore.us/developer-guide\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Coding Standards\",\"item\":\"https://docs.fusioncore.us/developer-guide/coding-standards\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.fusioncore.us/developer-guide/coding-standards#article\",\"headline\":\"Coding Standards\",\"name\":\"Coding Standards\",\"description\":\"The coding conventions every fusionCore contributor follows: clean code, review readiness, API versions, and metadata naming for managed and unmanaged packages.\",\"url\":\"https://docs.fusioncore.us/developer-guide/coding-standards\",\"mainEntityOfPage\":{\"@id\":\"https://docs.fusioncore.us/developer-guide/coding-standards#webpage\"},\"dateModified\":\"2026-07-09T17:43:31.180Z\",\"publisher\":{\"@id\":\"https://docs.fusioncore.us/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.fusioncore.us#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"fusionCore Documentation\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"fusionCore Documentation\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/developer-guide/coding-standards.md","siteName":"fusionCore Documentation","nav":{"global":null,"tabs":[{"tab":"End User Guides","pages":[{"title":"End User Guides","href":"/end-user-guides/platform-setup"}]},{"tab":"Developer Guide","groups":[{"group":"Developer Guide","pages":[{"title":"Developer Guide Overview","description":"Orientation for developers building on fusionCore: the package model, coding standards, and the shared infrastructure to build on.","href":"/developer-guide"},{"title":"Coding Standards","href":"/developer-guide/coding-standards"}]},{"group":"fusionCore Infrastructure","pages":[{"title":"Logging","description":"Structured logging with FCORE_BASE.Logger: log levels, the commit-by-DML vs commit-by-platform-event choice, and the canonical try/catch pattern.","href":"/developer-guide/logging"},{"title":"Caching","href":"/developer-guide/caching"},{"title":"DB Classes","href":"/developer-guide/db-classes"},{"title":"Utility Functions","href":"/developer-guide/utility-functions"},{"title":"Trigger Framework","href":"/developer-guide/trigger-framework"},{"title":"Event Framework","href":"/developer-guide/event-framework"},{"title":"Services","href":"/developer-guide/services"}]}]},{"tab":"API Reference","pages":[{"title":"API Reference","href":"/api-reference/introduction"}]}]},"basePath":"","title":"Coding Standards - fusionCore Documentation","deploymentId":"dpl_EwfxjeKENdVkfzdag8rM6mKzcTUJ","buildId":"dpl_EwfxjeKENdVkfzdag8rM6mKzcTUJ","dynamics":[],"chunks":[]}