Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions Naming Conventions Best Practice
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Best Practice: Stick to Consistent Naming Conventions for Variables, Functions, and Files to Ensure Readability and Ease of Future Modifications may be Camel notation or _ notation.
Why important: In ServiceNow development, adopting consistent naming conventions is crucial to maintaining code that is both readable and easily modifiable in the future. Whether you're writing scripts, creating workflows, developing UI actions, or configuring integrations, standardized naming
Ecample with out naming convensions:
var sD = rec.getValue('planned_start_date');
var eD = rec.getValue('planned_end_date');
return 'Start Date: ' + sD + ', End Date: ' + eD;
Example with naming convensions:
var plannedStartDate = changeRequestRecord.getValue('planned_start_date');
var plannedEndDate = changeRequestRecord.getValue('planned_end_date');
return 'Start Date: ' + plannedStartDate + ', End Date: ' + plannedEndDate;
Conclution:Following Naming conventions increase Readability,Maintainability and Scalability of out script.
1 change: 1 addition & 0 deletions Naming conventions
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Stick to consistent naming conventions for variables, functions, and files to ensure readability and ease of future modifications.
Loading