jamesw

jamesw

Agile Web Development with Rails 7: (page 118)

Title: AWDWR 7 (page 118)

You are styling the add to cart button inline in the actual HTML rather than the stylesheet as per previous versions of the book and goes against everything I’ve ever learned about Rails programming. Why is this? Is this a limitation of Tailwind?

Marked As Solved

rubys

rubys

Author of Agile Web Development With Rails

Welcome to Rails 7!

I’ve been with Rails since Rails 1. It seems every major release of Rails there are major paradigm shifts. Best practices change. Rails drives a number of these changes, and keeps up with others.

How Rails interacts with both JS and CSS is the biggest change with 7.0, and Tailwind’s integration is a bit further ahead that Rails’ integration with other CSS frameworks in two important ways: there is no node.js dependency, and the scaffold templates generated are enhanced.

As a book author, tailwind has allowed me to replace pages of text with lines of css atttributes. And hotwire allowed me to remove an entire chapter. The end result: a book that focuses more on Rails and less on web technologies.

Rest assured, if tailwind is not for you you are welcome to use a different CSS framework. Or no framework at all.

Popular Pragmatic Bookshelf topics Top

New
yulkin
your book suggests to use Image.toByteData() to convert image to bytes, however I get the following error: "the getter ‘toByteData’ isn’t...
New
simonpeter
When I try the command to create a pair of migration files I get an error. user=> (create-migration "guestbook") Execution error (Ill...
New
edruder
I thought that there might be interest in using the book with Rails 6.1 and Ruby 2.7.2. I’ll note what I needed to do differently here. ...
New
herminiotorres
Hi @Margaret , On page VII the book tells us the example and snippets will be all using Elixir version 1.11 But on page 3 almost the en...
New
alanq
This isn’t directly about the book contents so maybe not the right forum…but in some of the code apps (e.g. turbo/06) it sends a TURBO_ST...
New
New
jskubick
I’m under the impression that when the reader gets to page 136 (“View Data with the Database Inspector”), the code SHOULD be able to buil...
New
brunogirin
When installing Cards as an editable package, I get the following error: ERROR: File “setup.py” not found. Directory cannot be installe...
New
creminology
Skimming ahead, much of the following is explained in Chapter 3, but new readers (like me!) will hit a roadblock in Chapter 2 with their ...
New

Other popular topics Top

ohm
Which, if any, games do you play? On what platform? I just bought (and completed) Minecraft Dungeons for my Nintendo Switch. Other than ...
New
AstonJ
Inspired by this post from @Carter, which languages, frameworks or other tech or tools do you think is killing it right now? :upside_down...
New
Exadra37
Oh just spent so much time on this to discover now that RancherOS is in end of life but Rancher is refusing to mark the Github repo as su...
New
PragmaticBookshelf
A Hero’s Journey with Chris Pine @chrispine Chris Pine, author of Learn to Program, Third Edition, discusses his journey to beco...
New
Margaret
Hello everyone! This thread is to tell you about what authors from The Pragmatic Bookshelf are writing on Medium.
1132 25317 748
New
wmnnd
Here’s the story how one of the world’s first production deployments of LiveView came to be - and how trying to improve it almost caused ...
New
AstonJ
Saw this on TikTok of all places! :lol: Anyone heard of them before? Lite:
New
AstonJ
If you get Can't find emacs in your PATH when trying to install Doom Emacs on your Mac you… just… need to install Emacs first! :lol: bre...
New
PragmaticBookshelf
Author Spotlight: Sophie DeBenedetto @SophieDeBenedetto The days of the traditional request-response web application are long gone, b...
New
CommunityNews
A Brief Review of the Minisforum V3 AMD Tablet. Update: I have created an awesome-minisforum-v3 GitHub repository to list information fo...
New

Latest in PragProg Customers

View all threads ❯