Skip to content

Commit

Permalink
rome doesnt seem to correctly format tailwind classes
Browse files Browse the repository at this point in the history
  • Loading branch information
arthtyagi committed Nov 9, 2022
1 parent bf4d253 commit 2021aac
Show file tree
Hide file tree
Showing 19 changed files with 29 additions and 83 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
- Use `prettier` for formatting.
- Using [Airbnb Style Guide](https://github.com/airbnb/javascript) for ESLint with some modifications.

- In the process of migrating to Romev10. Use `bun rome` to run the linter/formatter. Prior to that, run `bun install` to install the dependencies. Why? `bun` is much faster even for a single command like this.
- In the process of migrating to Romev10. Use `bun [command]` to run the linter/formatter. Prior to that, run `bun install` to install the dependencies. Why? `bun` is much faster even for a single commands like these.

## Absolute Imports

Expand Down
1 change: 1 addition & 0 deletions apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
"scripts": {
"dev": "vite",
"build": "tsc && vite build",
"lint": "eslint --ext .js,.jsx,.ts,.tsx, src --fix",
"preview": "vite preview"
},
"dependencies": {
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/components/CommandPalette.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export default function CommandPalette() {
}, [handleKeyPress]);

return (
<Transition.Root show={open} as={Fragment} appear={true}>
<Transition.Root show={open} as={Fragment} appear>
<Dialog as="div" className="relative z-10" onClose={setOpen}>
<Transition.Child
as={Fragment}
Expand Down Expand Up @@ -170,7 +170,7 @@ export default function CommandPalette() {
'group flex items-center rounded-md px-4 py-4 text-sm',
'focus:ring-offset-neutral border-[1px] border-dashed border-neutral-800 focus:outline-none focus:ring-2 focus:ring-offset-2'
)}
end={true}
end
>
<item.icon
className="-ml-1 mr-3 h-6 w-6 flex-shrink-0"
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/components/forms/ChangeEmail.forms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export default function ChangeEmailForm(): JSX.Element {
loggedInUser.email ? loggedInUser.email : '[email protected]'
}
autoComplete="email"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:border-orange-500 focus:outline-none focus:ring-orange-500
dark:border-neutral-800 sm:text-sm"
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/components/forms/Login.forms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ export default function LoginForm({ loginError, setLoginError }: LoginFormProps)
type="email"
placeholder="[email protected]"
autoComplete="email"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -113,7 +113,7 @@ export default function LoginForm({ loginError, setLoginError }: LoginFormProps)
type="password"
placeholder="••••••••••••••••"
autoComplete="current-password"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -146,7 +146,7 @@ export default function LoginForm({ loginError, setLoginError }: LoginFormProps)
</div>

<div className="flex w-full justify-center">
<PrimaryButton isSubmitting={isSubmitting} wFull={true}>
<PrimaryButton isSubmitting={isSubmitting} wFull>
<span className="w-full">
{isSubmitting ? 'Signing In...' : 'Sign In'} <span></span>
</span>
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/components/forms/ResetPassword.forms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export default function PasswordResetForm(): JSX.Element {
placeholder="••••••••••••••••"
autoComplete="current-password"
aria-describedby="password-description"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -136,7 +136,7 @@ export default function PasswordResetForm(): JSX.Element {
placeholder="••••••••••••••••"
autoComplete="current-password"
aria-describedby="password-description"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -247,7 +247,7 @@ export function ForgotPasswordForm(): JSX.Element {
type="email"
placeholder="[email protected]"
autoComplete="email"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down
12 changes: 6 additions & 6 deletions apps/web/src/components/forms/Signup.forms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ export default function SignupForm({
type="text"
placeholder="John"
autoComplete="First Name"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -158,7 +158,7 @@ export default function SignupForm({
type="lastName"
placeholder="Doe"
autoComplete="Last Name"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -192,7 +192,7 @@ export default function SignupForm({
type="email"
placeholder="[email protected]"
autoComplete="email"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -227,7 +227,7 @@ export default function SignupForm({
placeholder="••••••••••••••••"
autoComplete="current-password"
aria-describedby="password-description"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand Down Expand Up @@ -273,7 +273,7 @@ export default function SignupForm({
type="password"
placeholder="••••••••••••••••"
autoComplete="current-password"
required={true}
required
className="dark:bg-darkBG mt-1 block w-full rounded-md border
border-neutral-300 py-2 px-3 shadow-sm focus:outline-none dark:border-neutral-800 sm:text-sm"
/>
Expand All @@ -297,7 +297,7 @@ export default function SignupForm({
<div>
{!signedUp ? (
<div className="flex justify-center">
<PrimaryButton isSubmitting={isSubmitting} wFull={true}>
<PrimaryButton isSubmitting={isSubmitting} wFull>
<span className="text-lg font-bold">
{isSubmitting ? 'Signing up...' : 'Sign Up'}{' '}
<span className="text-xs"></span>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ const router = createBrowserRouter([
{
path: '/meetings/past',
hasErrorBoundary: true,
element: <MeetingList past={true} />,
element: <MeetingList past />,
},
{
path: '/meetings/:uid',
Expand Down
8 changes: 4 additions & 4 deletions apps/web/src/pages/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export default function Layout({ children }: { children: React.ReactNode }) {
'flex items-center px-5 py-3 duration-300'
)
}
end={true}
end
>
<item.icon
className={classNames(
Expand Down Expand Up @@ -176,7 +176,7 @@ export default function Layout({ children }: { children: React.ReactNode }) {
'mb-1 flex w-1/4 justify-evenly rounded-xl border-t-2 border-transparent py-3'
)
}
end={true}
end
>
<tab.icon
className="h-8 w-8 flex-shrink-0"
Expand Down Expand Up @@ -249,11 +249,11 @@ export default function Layout({ children }: { children: React.ReactNode }) {
to="/social/circle"
className="ml-2 flex font-mono text-sm font-medium text-orange-200
duration-300 hover:text-white"
end={true}
end
>
<ArrowLeftIcon
className="mr-2 h-6 w-5 flex-shrink-0 text-gray-300"
aria-hidden={true}
aria-hidden
/>
Circle
</NavLink>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/pages/Login.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export function Login() {

<div className="mt-6">
<PrimaryButton
wFull={true}
wFull
onClick={() => {
setGithubLogin(true);
loginGithub();
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/pages/social/OneOne.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ function MatchCard({ username }: { username: string }): JSX.Element {
</button>
) : (
<button type="button" className={greenString}>
<CheckIcon className="mr-2 h-6 w-5" aria-hidden={true} />
<CheckIcon className="mr-2 h-6 w-5" aria-hidden />
<span>Added To Circle</span>
</button>
)}
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/pages/social/components/ActionDialogs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ export function ScheduleDialog({
className="rounded-md border-[1px] border-solid border-neutral-600 px-3 py-1 font-light text-slate-900
shadow-2xl shadow-white/20 invert filter duration-300 sm:px-3 lg:px-6"
step={900}
required={true}
required
/>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/pages/social/forms/SocialProfile.forms.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ export function SocialProfileForm(): JSX.Element {
}
}
}}
multiple={true}
multiple
>
{({ open }) => (
<>
Expand Down Expand Up @@ -588,7 +588,7 @@ export function SocialProfileForm(): JSX.Element {
}
}
}
multiple={true}
multiple
>
{({ open }) => (
<>
Expand Down Expand Up @@ -709,7 +709,7 @@ export function SocialProfileForm(): JSX.Element {
}
}
}}
multiple={true}
multiple
>
{({ open }) => (
<>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/pages/stream/Messages.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function MessagesNav({ user }: { user: string }): JSX.Element {
if (connected) {
return (
<NavLink
preventScrollReset={true}
preventScrollReset
key={user}
to={`/messages/${user}/`}
className={classNames(
Expand Down
Binary file modified bun.lockb
Binary file not shown.
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
"build": "turbo run build",
"dev": "turbo run dev --parallel",
"lint": "turbo run lint",
"rome": "rome check ./ --apply",
"format": "prettier --write \"**/*.{ts,tsx,md}\""
},
"devDependencies": {
Expand All @@ -33,7 +32,6 @@
"eslint-plugin-react-hooks": "latest",
"prettier": "2.7.1",
"prettier-plugin-tailwindcss": "latest",
"rome": "^10.0.0",
"turbo": "latest",
"typescript": "^4.8.4",
"workspace": "^0.0.1-preview.1"
Expand Down
2 changes: 0 additions & 2 deletions packages/config/eslint-react.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ module.exports = {
'prettier/prettier': ['error'],
'react-hooks/exhaustive-deps': 'warn',
'react-hooks/rules-of-hooks': 'error',
'react/jsx-boolean-value': 'off',
'react/jsx-indent-props': [2, 'tab'],
'react/jsx-indent': [2, 'tab'],
'react/jsx-one-expression-per-line': [0],
'react/prefer-stateless-function': [1],
Expand Down
9 changes: 0 additions & 9 deletions rome.json

This file was deleted.

42 changes: 0 additions & 42 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1554,36 +1554,6 @@
estree-walker "^2.0.2"
picomatch "^2.3.1"

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-darwin-arm64/-/cli-darwin-arm64-10.0.0.tgz#c219bbdc8a9d53a845b18f6df2affbff5b887b0b"
integrity sha512-JT7JccEtKyFDHXy0MxhwHN4Zc94s/kW+0aTczb1ChAoCStfjj5jWzv/yQnm+HFw5Vf3ukAocLsDNRN6d9gQYbQ==

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-darwin-x64/-/cli-darwin-x64-10.0.0.tgz#dbf8284c5013d61dbca25ab92027398274ee2e3a"
integrity sha512-HORYhz8eM3L3XePPNBhU44zFpTVfhpuO4B7fjdfho7z9kwTW22M0fVvuPrxxPauxmin7gHM8lxCD2jHxabg34Q==

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-linux-arm64/-/cli-linux-arm64-10.0.0.tgz#50b3fd210054fc68f2c92494f304d26ab5a8a7b1"
integrity sha512-/L3jxo9RUwJ+uvDvAPCquAw10ccpZDuzADfZff5tHd6Fzv28cAToC3JrN/2miGpur0Fx/NIZIPbAsdI4NWGIRA==

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-linux-x64/-/cli-linux-x64-10.0.0.tgz#5cd3611dc23fcefafaf642791950bc3c940b172d"
integrity sha512-KC6CDeSR4haRfxmfrvCn8+NzQ7X31pDjFgD+m+PAbSXOeMr/KHmU7eDsjC3d47ORYYkYXqhx9VxHe1w3IEShMg==

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-win32-arm64/-/cli-win32-arm64-10.0.0.tgz#6dfb064de3b9a4c35a89bf32635ba4e675ea85c6"
integrity sha512-8XWjx7Z1dMp9q4Lvi+ax4+Y8vkbp7JHVdfrTSMQTyUA9ofaW6ah1h9iGPuKic057VTZGX66/KazC5qNTbrlckQ==

"@rometools/[email protected]":
version "10.0.0"
resolved "https://registry.yarnpkg.com/@rometools/cli-win32-x64/-/cli-win32-x64-10.0.0.tgz#1c5132eb96bac7ba5da59ed7cddac32d33bc933b"
integrity sha512-mAf3f32oE919cZ86KVMR/X0VOs+C16jEUyt1ww2UPw/rKUmm0DNfuT6/m4FQW8GEHdCBC8z3zdRVCd05VK7UJg==

"@rushstack/eslint-patch@^1.1.3", "@rushstack/eslint-patch@^1.2.0":
version "1.2.0"
resolved "https://registry.npmjs.org/@rushstack/eslint-patch/-/eslint-patch-1.2.0.tgz"
Expand Down Expand Up @@ -7886,18 +7856,6 @@ rollup@^2.43.1, rollup@^2.79.0, rollup@^2.79.1:
optionalDependencies:
fsevents "~2.3.2"

rome@^10.0.0:
version "10.0.0"
resolved "https://registry.yarnpkg.com/rome/-/rome-10.0.0.tgz#ae1e291f4b3546881c1709597f7e2e679546fc56"
integrity sha512-dQnIlzgHDt94N4JoFaqe9e2aDAZfdmyGOW4UaefMztDph41mt75Mg0aeJ/C7JgcIOLbp9D4LD+omyUB5YFUUPw==
optionalDependencies:
"@rometools/cli-darwin-arm64" "10.0.0"
"@rometools/cli-darwin-x64" "10.0.0"
"@rometools/cli-linux-arm64" "10.0.0"
"@rometools/cli-linux-x64" "10.0.0"
"@rometools/cli-win32-arm64" "10.0.0"
"@rometools/cli-win32-x64" "10.0.0"

run-async@^2.4.0:
version "2.4.1"
resolved "https://registry.npmjs.org/run-async/-/run-async-2.4.1.tgz"
Expand Down

2 comments on commit 2021aac

@vercel
Copy link

@vercel vercel bot commented on 2021aac Nov 9, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 2021aac Nov 9, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

devclad-landing – ./apps/landing

devclad-landing-devclad.vercel.app
devclad-landing-git-main-devclad.vercel.app
devclad-landing.vercel.app
www.devclad.com
devclad.com

Please sign in to comment.