Using OpenAPI 3 with Node.JS - node.js

I would like to integrate OpenAPI 3 into my node.js project and take advantage of the Swagger tools that are available.
I noticed that the swagger npm module hasn't been updated in five years. There are other questions, such as this one (How to use OpenAPI 3.0 in Node.js?) which have basically gone unanswered.
A superficial web search yields me no results.
Does anyone have some ideas/suggestions on how to implement the OpenAPI 3.* standard into swagger apps in node? Even if you've found a tutorial or some description on how to do this manually, I would be most grateful for some direction and advice.
I tried just simply putting the OpenAPI 3 standard in the editor (swagger project edit) as you would the online editor, and it goes crazy with errors. I tried manually updating the swagger.yaml document, which also just leads to the node application crashing.
The updates from the new standard (3.* vs 2) are so much easier to read, implement and reuse, which is why I'm asking about this. Again, any direction or help would be greatly appreciated.

Swagger changed its name to OpenAPI starting with version 3.0 back in 2017. The company that originally created the Swagger standard (Smartbear) now uses the Swagger name for its own tooling, while the open standard goes by OpenAPI. This is why you're not seeing many tools that use the name Swagger.
Node.js is a very popular language, so there is an abundance of tooling available for OpenAPI 3.0. In the future, use the term "OpenAPI" when searching, and you'll get better results.
The popular site https://openapi.tools/ has a wide assortment of popular tools available that utilize OpenAPI, along with a list of what languages each tool uses. This is a great starting point, though there are many other tools out there.

Related

Does node js have a good library for speech-to-text?

Im working on a project in which the main feature of the project is voice recognition. Th e backend is developed in node, express, and mongo DB, and the frontend is in react-native. I have made a lot of research and tried a lot of examples trying to implement this feature in my application, but I couldn't find any.
I started looking for react-native libraries that might cover this feature, and I did find https://github.com/react-native-voice/voice
I tried to implement it in my project, but I got stuck with an error which is an open issue: https://github.com/react-native-voice/voice/issues/376
I also tried to find other libraries but they weren't good ones. Most of them were developed years ago and never updated.
So I thought to solve this feature in the backend.
I made a lot of research as well, and find a few libraries for speech-to-text, but their documentation wasn't enough, very few tutorials, and not a strong source code to support this feature.
So by far, I am to the conclusion that Node.js and React-native cannot support this feature.
The reason I choose to ask in StackOverflow is to make sure if my conclusion is right(to not waste time trying other libraries), and if it is right, should I try to implement these features by using another programming language(ex: Python), and if my conclusion is wrong, please feel free to share any documentation or solution about this feature.

Azure Function Webhook Templates

I'm starting to research and learn Azure Functions. Specifically I need to learn about webooks.
This video uses a template; https://azure.microsoft.com/en-us/resources/videos/create-a-web-hook-or-api-azure-function/
I have seen this in other tutorials/post on setting up an Azure Function to handle a Github webhooks.
When I create a new function I do not have any of these templates show up. I'm assuming they may need to be uploaded but I have searched and not found any information of where they may be located and how to import them.
Are these still available to use?
Thanks!
I believe that video is quite old. You can find the latest documentation which contains quite a few quickstarts and tutorials to get you started.
Also, while you can create functions from the portal, most of the development can be done locally which is usually preferred by most. Depending on your preference, you could develop using
Visual Studio Code
Visual Studio
CLI (along with any editor of your choice :D)
Also, there are a couple of supported languages from which you can choose from to develop for.

How do you make a Hapi.JS plugin/module?

I'm new to both Node and Hapi.js, but not to programming.
I've made a few simple Hapi.js servers, just for testing out Joi and other plugins.
I'm now trying to understand how best to package up chunks of functionality in a Hapi way, so we can re-use them in future projects and potentially share them with the world!
Are there any good resources for learning this available?
EDIT:
I've found a few good resources, but non which go into deep details about the plugin system.
https://github.com/hapijs/hapi/issues/1489 - Getting Started Tutorial Contest
https://github.com/otodockal/hapi-tutorial - Entry in above contest, with a section on plugins
I've made a sample project which groups functionality into plugins which might be what you're looking for:
https://github.com/johnbrett/hapi-level-sample
If you're looking at sharing functionality between plugins, look at the usage of plugin.expose, plugin.depend.
If you have any questions on it, you can raise an issue on the github project.
The latest hapijs.com website has a good intro as well: http://hapijs.com/tutorials/plugins
For some additional detail about hapi plugins (and hapi in general), see the following:
Developing a hapi Edge: A Rich Node.JS Framework for Apps and Services - This book is available now (also from Amazon), and has a chapter on how to create a plugin in hapi.
Matt Harrison's upcoming hapi.js in Action - This book is available currently in "MEAP" (Manning Early Access Program), and will soon (?) have a chapter available on plugins ("Building modular applications with Plugins").
hapi plugin search engine
Getting Started with hapi.js by John Brett also has a chapter on creating and using plugins.
Edit 2015-10-04: The chapter "Building modular applications with Plugins" in Matt Harrison's above mentioned book is now available in the MEAP edition.

Difference between P4.net and P4api.net

What is the exact difference between p4.net and p4api.net?
I was trying to create a custom gui based tool for perforce and I started developing it using p4api.net. Much later I came to know about the existence of p4.net. Now I am confused with their difference and the purpose.
Also I have a doubt on which option to choose for the development.
Is there something else other than these two?
P4API.NET is the supported API for .NET applications, so I'd go with that. You can see a list of the officially released APIs for the various languages here.

NodeJS Skinning

Is there a module or similar things that support skinning in NodeJS? I want to build a NodeJS website, and want to be able to re-skin the website as I like without much efforts, like in Wordpress.
Is skinning supported in NodeJS?
If you're interested in building a website in Node.js and don't need a wordpress-style cms behind it, there are few projects that can help you out.
Have you looked into Bootstrap? It's built with less which you can easily plug in to your Express setup (see the guide here, using the command line executable to set up a new project you can specify less like this: express --css less myapp and it will do all the work for you)
In the bootstrap less file are several variables you can use to change the colours, fonts, sizes, etc, and it's also got a lot of helpers for grid layouts and responsive designs.
It even includes a few useful javascript plugins too which make the ui nicer with less work.
There are also a lot of sites with themes and theme generators around which then work on top of bootstrap, and may achieve what you want.
Plugging in this sort of solution (whether bootstrap or other) is about as close as you can come to getting skinning for node; As otherwise suggested if you're looking for a CMS out of the box as well, probably best to look for another platform like Wordpress.
Node.js is not a content management system. It is a platform on top of which you could built a web server with a content management system. To answer your question you need to be looking for node.js based content management systems that support themes.
The only node.js CMS that I am aware of is Calipso. It's still pretty alpha-stage. It may have some theming support, but it is nowhere near as polished as Wordpress.
Also is there a reason why you want to use node.js? I mean there is nothing wrong in using Wordpress for creating a themeable website - it is just awesome for that.
If you just want another OnlineShop, or maybe a blog, i think nodejs is maybe not your right choose as Jed Watson told.
If your requirements are more complicated, and you want a quick and easy implementation of a nice web interface, and you have html, javascript, and css knowledge... I strongly recommend you just trying to work with MEAN.js
It puts together MongoDB Expressjs, AngularJs, and NodeJs.
Use this, for example with a yeoman fullstack constructor and you will have a powerful webapp, with user autentication, and much more in a few minutes.
After that, the use of jade, less, scss, and similar languages of modelling the front, and the easy way you can also model collections in the back, is for me the best combination you´ll find for creating a website today.
Hope it´ll help you
King Regards

Resources