Skip to content

Commit 37e3d43

Browse files
justin808claude
andcommitted
Fix Redux template to use CSS modules consistently
- Added CSS module import to Redux HelloWorld component - Changed from className="bright" to className={style.bright} - Updated React import to modern approach for consistency - Now matches the styling approach used in base template 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent dd9e6f8 commit 37e3d43

File tree

1 file changed

+3
-2
lines changed
  • lib/generators/react_on_rails/templates/redux/base/app/javascript/bundles/HelloWorld/components

1 file changed

+3
-2
lines changed

lib/generators/react_on_rails/templates/redux/base/app/javascript/bundles/HelloWorld/components/HelloWorld.jsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import React from 'react';
1+
import { useState } from 'react';
2+
import * as style from './HelloWorld.module.css';
23

34
const HelloWorld = ({ name, updateName }) => (
45
<div>
@@ -8,7 +9,7 @@ const HelloWorld = ({ name, updateName }) => (
89
</h3>
910
<hr />
1011
<form>
11-
<label className="bright" htmlFor="name">
12+
<label className={style.bright} htmlFor="name">
1213
Say hello to:
1314
<input id="name" type="text" value={name} onChange={(e) => updateName(e.target.value)} />
1415
</label>

0 commit comments

Comments
 (0)