Một mục mã nguồn mở trong kho dữ liệu GitHub của TopGit: node-red/node-red-nodegen, 179 sao, JavaScript. Command line tool to convert Node-RED function node, Swagger document, or WoT Thing Description to a custom Node.
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
Node generator is a command line tool to generate Node-RED nodes based on various sources such as an OpenAPI (Swagger) document, a Node-RED Function node, or a Web Of Things Thing description.
It helps developers dramatically reduce the time to implement Node-RED nodes.
Installation
Install node generator globally to make the node-red-nodegen command available on your path:
npm install -g node-red-nodegen
You may need to run this with sudo, or from within an Administrator command shell.
Usage
Usage:
node-red-nodegen <source file or URL> [-o <path to save>] [--prefix <prefix string>] [--name <node name>] [--module <module name>] [--version <version number>] [--keywords <keywords list>] [--category <node category>] [--icon <png or gif file>] [--color <node color>] [--tgz] [--help] [--wottd] [--encoding <encoding>] [--encodekey <encoding key>] [--lang <accept-language>] [-v]
Description:
Node generator for Node-RED
Supported source:
- OpenAPI document
- Function node (js file in library, "~/.node-red/lib/function/")
- Subflow node (json file of subflow)
- (Beta) Thing Description of W3C Web of Things (jsonld file or URL that points jsonld file)
Options:
-o : Destination path to save generated node (default: current directory)
--prefix : Prefix of npm module (default: "node-red-contrib-")
--name : Node name (default: name defined in source)
--module : Module name (default: "node-red-contrib-<node name>")
--version : Node version (format: "number.number.number" like "4.5.1")
--keywords : Additional keywords (format: comma separated string, default: "node-red-nodegen")
--category : Node category (default: "function")
--icon : PNG file for node appearance (image size should be 10x20)
--color : Color for node appearance (format: color hexadecimal numbers like "A6BBCF")
--tgz : Save node as tgz file
--help : Show help
--wottd : explicitly instruct source file/URL points a Thing Description
--encoding : Encoding scheme of subflow (none or AES)
--encodekey : Encoding key of subflow
--lang : Language negotiation information when retrieve a Thing Description
-v : Show node generator version
Example 1. Create an original node from OpenAPI document
-> You can use swagger-petstore node on Node-RED flow editor.
Example 2. Create an original node from function node (JavaScript code)
In Node-RED flow editor, edit the function node and to the right of the 'name' option, click on the book icon and select 'Save to library'. Then fill in the 'Export as' with the file name (lower-case.js).
-> You can use Example Thing node on Node-RED flow editor.
Example 5. Create an original node from SUBFLOW definition
In Node-RED flow editor, create the SUBFLOW template with module properties filled. Here, we assume module name for the SUBFLOW template is node-red-contrib-qrcode.
Export JSON definition of the SUBFLOW template from Export menu. We assume it is saved to a file named qrcode.json.
node-red-nodegen qrcode.json
cd ~/.node-red
npm install <path-to>/node-red-contrib-qrcode
node-red
-> You can use qrcode node on Node-RED flow editor.
Documentation
Use cases (Japanese)
How to use Node generator (Japanese)
Generated files which node package contains (Japanese)
How to create a node from OpenAPI document (Japanese)
How to create a node from function node (Japanese)
How to create a node from subflow (Japanese)
How to create a node from WoT Thing Description (Japanese)
Note: Currently node generator supports GET and POST methods using JSON format without authentication.
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/node-red/node-red-nodegen là nguồn chính thức.
node-red/node-red-nodegen có bao nhiêu sao?
node-red/node-red-nodegen có 179 sao GitHub — tải lại trang để xem số mới nhất, hoặc xem trực tiếp github.com/node-red/node-red-nodegen. TopGit phản chiếu số sao của GitHub nhưng không cam kết đến từng phút.
node-red/node-red-nodegen có phải mã nguồn mở không?
Có — node-red/node-red-nodegen phát hành theo license Apache-2.0, nghĩa là mã nguồn mở để đọc, fork và (tùy license) tái sử dụng. Mã: github.com/node-red/node-red-nodegen.
node-red/node-red-nodegen có website riêng không?
TopGit chưa ghi nhận URL trang chủ cho node-red/node-red-nodegen. Phần README ở tab phía trên thường có link demo, hoặc xem mô tả GitHub của repo.
node-red/node-red-nodegen là gì?
node-red/node-red-nodegen (node-red/node-red-nodegen) là dự án JavaScript trên GitHub. Theo mô tả gốc: Command line tool to convert Node-RED function node, Swagger document, or WoT Thing Description to a custom Node.
Đọc đầy đủ README ở tab phía trên.
Muốn nghe thêm một ý kiến về node-red-nodegen?
Hỏi một AI đọc được trang này — một cú bấm là có ngay nhận định về node-red-nodegen.