typescript-to-javascript
Reactive icon

TypeScript To JavaScript

version 1.0.0 (Compatible with OutSystems 11)
Uploaded
 on 23 July 2024
 by 
0.0
 (0 ratings)
typescript-to-javascript

TypeScript To JavaScript

Details
The TypeScriptToJavaScript app provides seamless conversion of TypeScript code to JavaScript. It features client actions to transpile and execute TypeScript, a web block for easy code conversion, and comprehensive CRUD operations for code management. This tool enhances development efficiency and code maintainability by leveraging TypeScript's static typing and modern development capabilities.
Read more

Client Actions

Convert Code: The Convert Code action is designed to facilitate the seamless conversion of TypeScript code into JavaScript. It takes two input parameters: TsCode and JsInputId. The TsCode parameter accepts the TypeScript code that needs to be transpiled, while JsInputId specifies the ID of the DOM element where the resulting JavaScript code will be displayed. This action processes the provided TypeScript code, converts it into JavaScript using a transpilation process, and assigns the transpiled JavaScript code to the specified DOM element. This ensures that the TypeScript code is efficiently converted and rendered as JavaScript within the web application.

RunJavaScript: The RunJavaScript action offers a robust solution for transpiling and executing TypeScript code in the browser. It accepts two parameters: TsCode and UniqueCode. The TsCode parameter is used to input the TypeScript code that needs to be converted and executed. The UniqueCode parameter is optional and, when provided, triggers a server call to retrieve stored TypeScript code from the database. The action then checks if the corresponding transpiled JavaScript code is already available in the database. If it is, the action fetches and executes this stored code, ensuring an optimized experience by avoiding redundant transpilation. This dual functionality makes the RunJavaScript action highly versatile, capable of handling both immediate code execution and optimized retrieval of pre-transpiled code.

Web Block

ConvertTsCode: The ConvertTsCode web block is a dedicated component that simplifies the process of converting TypeScript code to JavaScript. It takes TypeScript code as input and returns the corresponding transpiled JavaScript code. This web block encapsulates the transpilation logic, providing a straightforward and user-friendly interface for developers. By integrating this web block into the application, developers can easily convert TypeScript to JavaScript without delving into the complexities of the transpilation process. This not only enhances development efficiency but also ensures consistent and reliable code conversion across the application.

Release notes (1.0.0)
License (1.0.0)
Reviews (0)
Team
Other assets in this category