-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import type { Meta, StoryObj } from '@storybook/react' | ||
|
||
import LoginPage from './LoginPage' | ||
|
||
const meta: Meta<typeof LoginPage> = { | ||
component: LoginPage, | ||
} | ||
|
||
export default meta | ||
|
||
type Story = StoryObj<typeof LoginPage> | ||
|
||
export const Primary: Story = {} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { render } from '@redwoodjs/testing/web' | ||
|
||
import LoginPage from './LoginPage' | ||
|
||
// Improve this test with help from the Redwood Testing Doc: | ||
// https://redwoodjs.com/docs/testing#testing-pages-layouts | ||
|
||
describe('LoginPage', () => { | ||
it('renders successfully', () => { | ||
expect(() => { | ||
render(<LoginPage />) | ||
}).not.toThrow() | ||
}) | ||
}) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { Link, routes } from '@redwoodjs/router' | ||
import { MetaTags } from '@redwoodjs/web' | ||
|
||
const LoginPage = () => { | ||
return ( | ||
<> | ||
<MetaTags title="Login" description="Login page" /> | ||
|
||
<h1>LoginPage</h1> | ||
<p> | ||
Find me in <code>./web/src/pages/LoginPage/LoginPage.tsx</code> | ||
</p> | ||
<p> | ||
My default route is named <code>login</code>, link to me with ` | ||
<Link to={routes.login()}>Login</Link>` | ||
</p> | ||
</> | ||
) | ||
} | ||
|
||
export default LoginPage |