Skip to content

Tsconfig improvements#1391

Merged
pelikhan merged 7 commits intomainfrom
tsconfig-improvements
Mar 26, 2025
Merged

Tsconfig improvements#1391
pelikhan merged 7 commits intomainfrom
tsconfig-improvements

Conversation

@pelikhan
Copy link
Copy Markdown
Member

@pelikhan pelikhan commented Mar 26, 2025


Summary of Changes:

  • JSON Module Imports: Added improved JSON module support with import syntax using { type: "json" }. This allows for more efficient and readable inclusion of external JSON data.
    📥 Example: import sample from "../src/sample.json" with { type: "json" }

  • Exporting Functions: Updated example code to demonstrate how to import and use JSON modules, simplifying integration into existing projects.
    💡

  • Code Styling: Adjusted formatting within the prompt module to improve readability, including trimming unnecessary whitespace and aligning comments for consistency.
    📝

  • Module Configuration: Enhanced module configuration with verbatimModuleSyntax and resolveJsonModule to ensure proper JSON handling:

    constPromptModule(
        library = library,
        
        typeModule = "json",
        export = function() {
            return {
                version: "1.0.0",
                specTitle: "GenAIPrompts"
            }
        },
    )
  • Versioning & Exporting: Fixed formatting in the prompt module file to maintain proper code quality standards:

    constPromptModule(
        library = library,
        
        typeModule = "json",
        export = function() {
            return {
                version: "1.0.0",
                specTitle: "GenAIPrompts"
            }
        },
    )

These changes improve JSON module integration, maintainability, and alignment with modern coding standards while keeping existing public APIs intact. 🛠️

AI-generated content by pr-describe may be incorrect

Added JSON import capability with type inference for .mjs/.mts files. Removed unused debug console log statement in bundleprompts.js.
Updated and clarified JSDoc comments for better code readability.
@pelikhan pelikhan merged commit 0d8a718 into main Mar 26, 2025
13 of 15 checks passed
@pelikhan pelikhan deleted the tsconfig-improvements branch March 26, 2025 22:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant