Heroku version: that working: https://intense-escarpment-64234.herokuapp.com/baa/old-2019 Vercel version that not working: https://react-sendgrid-form.vercel.app/
First, run the development server:
npm run dev
# or
yarn dev
Open http://localhost:3000 with your browser to see the result.
npm run dev
- starts development server
npm run build
- make build and HMTL build in out/
folder
npm run lint
- eslint auto fix
components/
- Folder with components
components/Layout
- Main layout component
components/Layout/Nav
- Navigation component with all form routes
pages/api/send-email.js
- email sending function
pages/baa/[forms].js
- dynamic route for email forms
pages/_app.js
- component for initialize pages
pages/index.js
- Template routing!
- https://hackernoon.com/5-reasons-why-newsletters-should-be-part-of-your-business-strategy
- https://hackernoon.com/organizing-an-advanced-structure-for-html-email-template
- https://hackernoon.com/how-i-started-to-build-react-components-for-email-templates
- https://hackernoon.com/introducing-a-simple-npm-module-with-email-templates
- https://hackernoon.com/glossary-for-non-technies
- https://hackernoon.com/email-marketing-and-how-to-curate-an-effective-business-newsletter
- https://hackernoon.com/exploring-substack-for-building-your-newsletter
- https://hackernoon.com/building-a-design-system-for-email-templates-react
- https://hackernoon.com/together4victory-list-of-email-marketing-tools
- https://hackernoon.com/cool-newsletters-for-developers-part-1
- https://hackernoon.com/cool-resources-for-sending-emails
- Name: Old 2019 version
Template ID: d-dc18336cd62d40fba8820bccb351aa8f
no variables
- Name: BAA Credits Finished #sponsors
Template ID: d-5ae6d711deb14a8485a60d7f247cd117
variables
{ "first_name": string }
- Name: got flagged as BAA #sponsors
Template ID: d-722b54a3b56a497a9c9124d273b7f641
variables
{ "first_name":"string", "article_link":"string", "article_title":"string", "brand":"string" }
- Name: promotional story detected #writers
Template ID: d-87d998d5e4064de1be6dc56b0790b9fb
variables
{ "full_name": "string", "url":"string", "time":"string" }
- Name: Brand As Author Credits Purchased V1
Template ID: d-1b0b9282b2bb4b18b5056a22aa25f8fb
no variables
- Name: Brand as Author Story Submitted #sponsors
Template ID: d-1b9ad22192214fb48ed3134fca11ea7a
variables
{ "handle": "string", "storyTitle": "string", "hasCredits": boolean }
- Name: Hacker Noon Enquiry Form
- About Your Hacker Noon Story: BAA Template ID: d-61b15100fada4f8abc440dcd067c6e20
variables none
Template ID: d-c9c2606f81064defb31d2c221c078ffd
variables none
Template ID: d-33edeaf8e9be4e1a8bf1fc8138436aae
variables none
Code samples:
- https://stackoverflow.com/questions/56109870/how-to-send-email-with-reactjs-and-sendgrid
- https://medium.com/swlh/how-to-use-sendgrid-to-send-emails-76c514c56782
- https://www.twilio.com/blog/gatsby-email-contact-form-react-serverless
Deploy it to the cloud with Vercel (Documentation).