You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Before doing anything, please check the versions of the gem files:
gem'rails','~> 5.1.4'gem'devise','~> 4.4.0'
Disclaimer - This solution may not work with older versions of rails and devise. Versions listed above were the latest versions of gems which I was using at the time of creation and tests. (10 Jan 2018)
Guide on how to create an API-Only Application with Ruby on Rails 5
Creating an API-Only Application with Ruby on Rails
01 - Create a new API-only Rails app
rails new ror-app-name --api
02 - Basic Scaffold
01 - Model
This step is for creating a very basic level of model for us to work in. If you know already, or wish to apply your own custom models with relationships you can skip this step.
Guide on how to work with development branch and merge with master
Working with development branch and merge with master
Sometimes you want to experiment with a code which you have on your master branch but not want to save it to master branch. In this case, you can create another branch where you can experiment with ease - and if you are satisfied, you can merge the experiment to the master branch later.
Creating development branch
git branch development
git checkout development
git add .
git commit -m "Initial commit on development branch"
git push origin development
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Guide for updating Tailwind to version 3 for Craft CMS & Laravel Mix
Tailwind v3 update for Craft CMS & Laravel Mix
When updating Tailwind to version 3, it caused some issues where just by saving the .twig file didn't show the results directly; with new ability where Tailwind v3 purged unused Tailwind classes, it added an additional step for a developer had to save either .scss file or .js file in order to recompile the assets, thus able to repurge the style sheet so that it displays and updates the newly saved class in .twig file.
After doing some research with numerous trial and errors, I realized Laravel Mix v6 allowed saving the .twig file to recompile the assets automatically, thus smoothing out the workflow even better.
Update Guide
Disclaimer - Note that this update guide is specific for upgrading Craft CMS which uses Laravel Mix v5 and Tailwind v2 to Laravel Mix v6 and Tailwind v3.