Challenge Overview

Our client is transforming its CRM, Self Serve, and Console services in Salesforce across business units, resulting in more than 1,600 Apex Classes, 100 triggers and voluminous LWC codes introduced by developers. This presents challenge in the following areas:

  • Accurately identifying potential impacts when introducing change

  • Potentially introducing duplicate logic; requiring build effort that should not be needed in the first place

  • Possibility of breaking the flow performing defect fixes

 

To simplify this we are going to build a Salesforce Apex Code and Metadata Analyser CLI that will extend the SFDX CLI to parse Salesforce artefacts offline and generate a symbol tree/dependency tree script (ClassDiagram script) that can be used to generate the UML diagram using Mermaid-JS. Ref this live editor for a quick demo. 

 

It’s a learning challenge that will guide you to set-up Salesforce env & dependencies CLI required to participate in the challenges & F2Fs of this series.

Technology Stack

General requirements

Code Formatting

  • Make sure code is well documented, all classes, methods, variables, parameters, return values must be documented in every single code file, and appropriate inline comments should be provided too where the code is not straightforward to understand.

  • Please use clean INDENTATION for all the code so future developers can follow the code.

  • Use appropriate linter to validate your code.

JAVASCRIPT SPECIFIC

  • Code written in JavaScript should pass the EsLint Validation.

LAYOUT

We don’t have a storyboard/design for the extension. You can use your best judgment for the layout.

PLATFORM

An extension should be created for VS-Code running on Windows, Linux & Mac

REFERENCES:

img

 

Business Requirements

1. Registering a Salesforce account

Go to https://developer.salesforce.com/ & register a salesforce account by entering the required details.

 

Enabling Dev Hub

Go to the Setup using the Gear Icon on the upper right corner & enable the “Dev Hub” option.

 

2. Set Up Your Salesforce DX Environment 

Setup your Salesforce DX environment by following the instructions here.

 

3. Set Up Visual Studio Code

Install Salesforce Extensions for Visual Studio Code by following the instructions here.

 

4. Create a Hello World Lightning Web Component

Now that you’ve set up your development environment, you can create a simple Lightning web component. This will make sure that the environment setup is correctly done & you have all the prerequisites to participate in the challenges of this series.

 

5. Setting up Dependencies CLI

Follow the instructions listed here to steup the dependencies-cli & complete all the steps till 4.Authorize an org. 

As a verification of setting up this correctly you need to take a snapshot of:

Steps 3. Test the plugin `sfdx dependency` &

Step 4. Authorize an org

& add it to the document you are going to submit.



Final Submission Guidelines

Submit a document containing the “Assessment Complete” snapshots of setup 2, 3 & 4 along with the URL for the hello world LWC you created.

You also need to include the snapshots asked in 5. Setting up Dependencies CLI

ELIGIBLE EVENTS:

2021 Topcoder(R) Open

REVIEW STYLE:

Final Review:

Community Review Board

Approval:

User Sign-Off

SHARE:

ID: 30139580