You are viewing limited content. For full access, please sign in.

Question

Question

Context-Aware JavaScript Autocomplete & Code Validation in Laserfiche Forms Designer

asked on May 19, 2025

We spend a significant amount of time customizing forms in the Modern Forms Designer with LFForm-based JavaScript. While the built-in sandbox is helpful, authoring code without IntelliSense or validation often leads to typos, missing brackets, or mis-referenced field IDs—errors that only surface at runtime.

Feature request

I would like to propose two complementary enhancements to the JavaScript editor within Forms:

  1. Context-aware autocompletion

    • Suggest LFForm methods, events (LFForm.onFormInitialized, etc.) and common JavaScript syntax.

    • Surface the current field IDs / CSS classes defined in the form so they can be inserted without manual copy-paste or using tokens.

    • Provide inline documentation tool-tips (signature + brief description) for built-in LFForm functions.

  2. One-click code validation / linting

    • A "Validate" tab or button that performs static analysis before saving, highlighting syntax errors and undefined references.

    • Ideally, show line-by-line error messages and warnings (similar to ESLint) so issues are fixed proactively.

Benefits

  • Fewer production errors: Catch mistakes early, reducing troubleshooting time.

  • Faster development: Autocomplete accelerates coding and encourages consistency in naming.

  • Lower learning curve: New users see available APIs and field IDs without digging through documentation.

  • Improved code quality: Built-in linting enforces best practices across teams.

Thank you. 

2 0

Replies

replied on April 10

This is something I'm going to show off at Empower this year and release to github. It won't be directly supported by Laserfiche but it should help anyone get started using JS (or typescript) locally and build modular code without needing to touch the form js editor.

1 0
replied on April 11

That would be spectacular! It would likely save a lot of headaches when working with JavaScript. This is a great contribution, congratulations. I hope I’ll be able to access it once everything is ready.

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.