Skip to content

Commit

Permalink
chore(core): Added support for ~ imports
Browse files Browse the repository at this point in the history
  • Loading branch information
wootsbot committed Jul 27, 2023
1 parent e754407 commit 56e9281
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .changeset/quick-pens-shake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'x-boilerplate': patch
---

support for `~` imports
1 change: 1 addition & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
// `react` come first.
["^next", "^react"],
// all pakages
["^~/?\\w"],
["^@?\\w"],
["^@/machines", "^@/libs"],
["^@/utils"],
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/pull_request_stats.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ env:
SECRET: ${{ secrets.SECRET }}
NEXTAUTH_URL: ${{ vars.NEXTAUTH_URL }}
NODE_VERSION: ${{ vars.NODE_VERSION }}
RESEND_API_KEY: ${{ secrets.RESEND_API_KEY }}
RESEND_DOMAIN: ${{ vars.RESEND_DOMAIN }}
NEXT_PUBLIC_SITE_URL: ${{ vars.NEXT_PUBLIC_SITE_URL }}
SITE_NAME: ${{ vars.SITE_NAME }}
SITE_URL: ${{ vars.SITE_URL }}
TWITTER_CREATOR: ${{ vars.TWITTER_CREATOR }}

jobs:
format:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ env:
SECRET: ${{ secrets.SECRET }}
NEXTAUTH_URL: ${{ vars.NEXTAUTH_URL }}
NODE_VERSION: ${{ vars.NODE_VERSION }}
RESEND_API_KEY: ${{ secrets.RESEND_API_KEY }}
RESEND_DOMAIN: ${{ vars.RESEND_DOMAIN }}
NEXT_PUBLIC_SITE_URL: ${{ vars.NEXT_PUBLIC_SITE_URL }}
SITE_NAME: ${{ vars.SITE_NAME }}
SITE_URL: ${{ vars.SITE_URL }}
TWITTER_CREATOR: ${{ vars.TWITTER_CREATOR }}

jobs:
stats:
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@

- 🛡️ Authentication for Next.js [NextAuth](https://next-auth.js.org/)

- ✉️ Send emails with [Resend](https://resend.com) and [@react-email](https://react.email/docs/integrations/resend)

- 📑 [Finite state machines](./src/machines)

- 📄 [react-hook-form](https://react-hook-form.com/) - Forms with easy-to-use validation
Expand Down
4 changes: 2 additions & 2 deletions app/(marketing)/resend/InviteEmail.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/* eslint-disable react/no-unescaped-entities */
import * as React from 'react';

import env from '~/env';

import {
Body,
Button,
Expand All @@ -17,8 +19,6 @@ import {
Text,
} from '@react-email/components';

import env from '~/env';

interface InviteEmailProps {
invitedByUsername?: string;
inviteLink?: string;
Expand Down
5 changes: 3 additions & 2 deletions app/api/resend/email/route.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { NextResponse } from 'next/server';

import InviteEmail from '~/app/(marketing)/resend/InviteEmail';
import env from '~/env';

import { Resend } from 'resend';

import { emailSchema } from '@/hooks/services/resend/email/email.schema';
import InviteEmail from '~/app/(marketing)/resend/InviteEmail';
import env from '~/env';

const resend = new Resend(env.RESEND_API_KEY);

Expand Down

1 comment on commit 56e9281

@vercel
Copy link

@vercel vercel bot commented on 56e9281 Jul 27, 2023

Choose a reason for hiding this comment

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

Please sign in to comment.