Integrating Svelte into Phoenix 1.6+ esbuild based workflow - phoenix-framework

There are a few pieces of information/code about compiling Svelte files with esbuild
https://github.com/EMH333/esbuild-svelte
https://esbuild.github.io/plugins/#svelte-plugin
for example. How does one correctly integrate those (or whatever else works well for this) into Phoenix 1.6+ mix environment?

Based on this article, you can use Svonix for that.

Related

Using JS GraphQL Plugin with makeExecutableSchema

I am writing a web app in WebStorm based on GraphQL. The web app is comprised of two components (i.e. frontend and backend). On the backend, I am using makeExecutableSchema to create multiple schemas and then merging them together to help maintain my code.
The frontend relies on a WebStorm plugin called JS GraphQL that helps interpret GraphQL mutations and queries as described here. The plugin expects to see a .graphql file to understand typedefs. I can manually copy/paste information from the backend to the frontend directories. Ideally, I would automatically generate the .graphql file for the frontend during the backend coding. Does anyone have insight on how to accomplish this?
Have you looked into graphql-code-generator? It has a plugin architecture and so can be adapted to a variety of needs. I've been on teams that have used it successfully on a few projects, and it's not hard to hook up to CI or whatever.

OctoberCMS (Laravel) + Vue.js + Tailwind CSS Best Setup

I am new with OctoberCMS. There are few tutorials in the internet. May I ask what is the best setup may I use or possible setup may I use with this web tech stacks?
We have a project and the requirement is we need to use octobercms so that's why we have to used this octobercms.
Possible Setup:
Micro Service Setup?
Two seperate folder for OctoberCMS and Vue.js. The communication would be an API Request calls.
Then for the deployment part for the production, we will use the dist folder from Vue.js Folder. I'm not 100% sure but I think this will be my initial thought that will be possible.
May I ask for any suggestions or clarifications on what will I use project setup. Thank you.
While it would be entirely possible to have two separate web properties with October providing the API, you can also just use Vue within an October CMS theme itself. See https://github.com/scottbedard/vuetober for more information on doing that.
If your project is more of a traditional CMS requirement then I would recommend at least trying the Vuetober approach. If it's a lot more complex and is mostly utilizing October for its powerful backend features, then the API-only approach could work fine too.
The main reason you'd want to go with running vuetober is if you were going to be utilizing the AJAX framework provided by October. You can still technically use it even when October is being run as a headless CMS just providing an API, but it gets more complicated with CORS and some other stuff you have to setup to make sure it works properly.

Plain MEAN Stack or a MEAN Framework like mean.io?

I have very decent HTML and CSS skills and a basic understanding of JavaScript. I'm currently designing a system where different users can store an inventory list (a separate list for each user).
I started with plain Mongo, Express, Angular and Node Stack. But when researching about user authentication in MEAN-Stack I stumbled across Mean.io which seems to have a build-in user auth/management.
Is it usefull for a beginner to start with such a MEAN Framework or better to stay at the basics for a first try?
MEAN frameworks like MEAN.io or MEAN.js are great for structuring an app but you still have to understand how everything works. It may be better to go with tutorials from scratch to learn then use a framework once you want to actually build an app. Start with a node/express server using a simple html/js page to understand API creation then add angular to learn the frontend stuff. This will help you understand what MEAN.xx is doing with regards to the frontend vs backend. MEAN.js for example puts all the backend (E and N) stuff in the server/ folders and the frontend (A) stuff in client/ folders.

Play! 2.0 with Scala and AJAX tutorial/example

I am looking for a clean vanilla example of the play framework with ajax. I would like to build a a dependent dropdown and a chained select. All the tutorials on the web I have found uses php.
The only sample that has ajax makes use of coffee script.
Is there one out there somewhere?
You don't really need a Scala tutorial for that, you can follow the PHP ones.
The difference is that your data (responses) will be returned by Scala routes instead of PHP scripts.
To learn more about AJAX calls in Play just examine a zentasks sample delivered to you together with Play's code. There are samples for both Scala and Java versions and all you have to test them is to go to the folder of selected sample via commandline and run/start it as a common Play's application.
Preview

php framework with plugins for spreadsheet generation, login/user system,twitter bootstrap integration?

I am considering php framework Codeigniter & Cakephp for small site I would be developing but I am open to using pretty much any framework does fullfill the following requirements. requirements are:
A simple pre-build user authentication system or login system as a plugin, something long
the lines of php-login-script.
Allows Easy integration with third-part excel/spreadsheet generation library or
has some plugin.
Should support PHP 5.2, hence symfony2 can't be considered
Bonus points if the framework
has integration with twitter
bootstrap
Looking for framework which can fullfill all of the above points, so I can save some time. Else, I would prefer framework which does most of the requirements & would write rest myself.
So, based on above requirements; which php framework/script would you suggest?
CakePHP2
User plugin https://github.com/cakedc/users
Twitter Bootstrap https://github.com/slywalker/TwitterBootstrap
There are plenty of different xls export helpers. Just google it and review them I can not recommend any of them because I have not used them. We have our own but we did not open source it.
Overall I would recommend to use CakePHP2 in any case over Codeigniter. I've recently had to convert a project from CI to Cake and now I know why... ;)
I don't know codeIgniter very well, but for Cakephp I can tell you that:
Authentifiaction is easy to implement.
It's easy to generate xml (which Excel can open), for .xls you'll have to do all by yourself.
supports 5.2
there is a helper for twitter bootstrap, but I've never used it.
For me the deal breaker concerning CodeIgniter is the lack of built-in ORM. You should consider if you need one or not.

Resources