Progressive web apps are the future of web apps. Please provide a project template for amber new command with stenciljs.com
@ansarizafar thank you for submitting your request.
We would appreciate if you can provide more context (detail and information) about why we should include this template for progressive web apps, please make a case by following our issue template and guidelines.
Your request is very much appreciated.
Why not Vue.js or React or Angular 4 ? Ain't these more popular ? :sweat_smile:
@ansarizafar thanks for providing the information of https://stenciljs.com/docs/intro
I think stenciljs has potential and providing a pure javascript solution over another framework has merit. We will look into this as a possible SPA generator candidate.
Regarding if "progressive web apps" are the future of web apps, it really depends on what you are building. I find a traditional web app much easier to build, maintain, scale and follow the RESTful principles which makes the Internet happy.
Also, I'm not a fan of how these JS frameworks fake out the browser history and other hacks to get a SPA to even work properly. The # in the URL for example and react router is just ... tacky.
With that said, there is some merit behind SPAs and from a usability perspective, you can do things like animated transitions between pages, so that is nice.
But if I was building an Application, I would think a native app will always be the best option. Possibly with React Native ???
I digress.
@drujensen I know Rails have something useful for reload pages faster :point_right: https://github.com/turbolinks/turbolinks, I think django and phoenix also have similar tools.
Currently you can build an app/website entirely with JavaScript.
Sails.js born as a project to make a rails for Node, but is very slow and JavaScript syntax isn't to maintainable. TypeScript/Flow are good approach and I like them.
But Hey, Amber is made in Crystal :sweat_smile: Allowing us to be faster, good syntax, without VM, compiled to binary and have a small footprint.
I think Amber/Crystal will be a fast/easy/fun webframework to make APIs, SPA apps, websites, chats, mailserver, and other stuff in backend side, so we can reuse the whole frontend ecosystem.
We just need a best documentation and a stable language that could be coming very soon.
@faustinoaq Yeah, I'm very familiar with the JS world and I have used many JS frameworks including Ext.js, sails.js, Backbone, Angular 1, and now React/Redux. I would lean toward Vue.js if I was going to pick on a green field project today.
I'm also very familiar with Rails turbo links and disable it on all new projects. ;-)
I find traditional request/response apps can handle many of the needs of web applications built today. Especially any non-customer facing site or internal utility apps. They do not require any sort of complexity that these frameworks bring.
Yes, if you are building a really cool customer facing Web Application and SPA is the best solution, you should go that route. BUT, if you are building a simple CRUD non-customer facing management interface, why would you ever incur the cost of React or some other SPA?
PWAs are becoming like native apps. They can be installed on the home screen, support Offline mode and push notifications. I like Vuejs, I have developed https://restock.gitlab.io with Vuejs but Vue is a framework whereas Stencil in a compiler for web components. Stencil startup template is a PWA out of the box and has a rich set of ionic components. Stencil components can be rendered on a Nodejs server and I think we can create a wrapper for Crystal. Search engine bots can also run javascript so SEO is not a problem anymore.We can also use urls without #
@ansarizafar thanks for the information. It's hard to stay on top of all the new and shiny toys, especially in the JS world.
So PWA is taking SPA to the next level and adding storage, offline capabilities and a desktop icon. Cool, pretty much a native app without the app store but still stuck in a browser.
...but still stuck in a browser.
So, backend is still needed and Amber is a good choice :wink:
Why stencil? Instead of amillionother.js frameworks?
Just my two cents to not burden or lock Amber with any particular JS framework or even a "Rails Asset Pipeline" like custom hand-rolled solution.
Instead, I think it will be prudent to look towards npm/yarn ecosystem and leverage their hardwork for a frontend build pipeline and just have it integrate nicely into an Amber project.
This leaves Amber in a better spot due to the following:
@jasdeepsingh We agree with you. That is what we currently provide. A very stripped down webpack and yarn/npm package.json file. It does the bare minimum to provide an asset pipeline.
https://github.com/amberframework/amber/tree/master/src/amber/cli/templates/app/config/webpack
https://github.com/amberframework/amber/blob/master/src/amber/cli/templates/app/package.json.ecr
I think this request for an SPA generator is still viable, but it's a low priority for the team right now.
Closing this issue.