-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
You'll note that we're using the tinify npm package which is developed here. Handily this package ships with TypeScript definitions, so we don't need to install a separate types package.
We're going to initialise a simple Node.js console application called "tinify" using TypeScript and ts-node:
It's a good idea to optimise our images; to make sure they're not unhelpfully large. We can do this manually using tools like TinyPNG or Squoosh. However, it's also possible to automate this process. In this post, I'll show you how to do that using the TinyPNG API.