Giter VIP home page Giter VIP logo

joeprevite.com's Introduction

Gatsby

Gatsby's default starter

Kick off your project with this default boilerplate. This starter ships with the main Gatsby configuration files you might need to get up and running blazing fast with the blazing fast app generator for React.

Have another more specific idea? You may want to check out our vibrant collection of official and community-created starters.

πŸš€ Quick start

  1. Create a Gatsby site.

    Use the Gatsby CLI to create a new site, specifying the default starter.

    # create a new Gatsby site using the default starter
    gatsby new my-default-starter https://github.com/gatsbyjs/gatsby-starter-default
  2. Start developing.

    Navigate into your new site’s directory and start it up.

    cd my-default-starter/
    gatsby develop
  3. Open the source code and start editing!

    Your site is now running at http://localhost:8000!

    Note: You'll also see a second link: http://localhost:8000/___graphql. This is a tool you can use to experiment with querying your data. Learn more about using this tool in the Gatsby tutorial.

    Open the my-default-starter directory in your code editor of choice and edit src/pages/index.js. Save your changes and the browser will update in real time!

🧐 What's inside?

A quick look at the top-level files and directories you'll see in a Gatsby project.

.
β”œβ”€β”€ node_modules
β”œβ”€β”€ src
β”œβ”€β”€ .gitignore
β”œβ”€β”€ .prettierrc
β”œβ”€β”€ gatsby-browser.js
β”œβ”€β”€ gatsby-config.js
β”œβ”€β”€ gatsby-node.js
β”œβ”€β”€ gatsby-ssr.js
β”œβ”€β”€ LICENSE
β”œβ”€β”€ package-lock.json
β”œβ”€β”€ package.json
└── README.md
  1. /node_modules: This directory contains all of the modules of code that your project depends on (npm packages) are automatically installed.

  2. /src: This directory will contain all of the code related to what you will see on the front-end of your site (what you see in the browser) such as your site header or a page template. src is a convention for β€œsource code”.

  3. .gitignore: This file tells git which files it should not track / not maintain a version history for.

  4. .prettierrc: This is a configuration file for Prettier. Prettier is a tool to help keep the formatting of your code consistent.

  5. gatsby-browser.js: This file is where Gatsby expects to find any usage of the Gatsby browser APIs (if any). These allow customization/extension of default Gatsby settings affecting the browser.

  6. gatsby-config.js: This is the main configuration file for a Gatsby site. This is where you can specify information about your site (metadata) like the site title and description, which Gatsby plugins you’d like to include, etc. (Check out the config docs for more detail).

  7. gatsby-node.js: This file is where Gatsby expects to find any usage of the Gatsby Node APIs (if any). These allow customization/extension of default Gatsby settings affecting pieces of the site build process.

  8. gatsby-ssr.js: This file is where Gatsby expects to find any usage of the Gatsby server-side rendering APIs (if any). These allow customization of default Gatsby settings affecting server-side rendering.

  9. LICENSE: Gatsby is licensed under the MIT license.

  10. package-lock.json (See package.json below, first). This is an automatically generated file based on the exact versions of your npm dependencies that were installed for your project. (You won’t change this file directly).

  11. package.json: A manifest file for Node.js projects, which includes things like metadata (the project’s name, author, etc). This manifest is how npm knows which packages to install for your project.

  12. README.md: A text file containing useful reference information about your project.

πŸŽ“ Learning Gatsby

Looking for more guidance? Full documentation for Gatsby lives on the website. Here are some places to start:

  • For most developers, we recommend starting with our in-depth tutorial for creating a site with Gatsby. It starts with zero assumptions about your level of ability and walks through every step of the process.

  • To dive straight into code samples, head to our documentation. In particular, check out the Guides, API Reference, and Advanced Tutorials sections in the sidebar.

πŸ’« Deploy

Deploy to Netlify

joeprevite.com's People

Contributors

allcontributors[bot] avatar bam92 avatar beraliv avatar billylevin avatar dependabot-preview[bot] avatar jatin2003 avatar javila35 avatar jsjoeio avatar kuldeepkeshwar avatar laurosilvacom avatar lautarolobo12 avatar maxcell avatar nutlope avatar willjohnsonio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

joeprevite.com's Issues

Embed Tweets in Posts

Summary

The ability to embed tweets inside posts/content.

Basic example

image

Motivation

Small enhancement to the reader's experience πŸ˜„

Customize Schema for Tags

Summary

I want to add some validation to categories (when I add them)

Basic example

Kyle proposed customizing my schema

Tweet thread

Motivation

  • ensure that I only use tags which have icons/images (when I add them)
  • avoid mistyping a tag (javascrpt vs javascript)

When I implement this, add @gillkyle to the contributor's table

Can't sign up for newsletter

Describe the bug
You can't sign up for the newsletter.

To Reproduce
Steps to reproduce the behavior:

  1. Go to site
  2. Add email to form
  3. Click subscribe
  4. Open console
  5. See "Invalid Token" error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

Pointed out by @petercr

New Page: /uses

Summary

Add a new page /uses

Basic example

  • new page in /pages
  • new folder in /content/pages and then transform Markdown to pages at build time

Motivation

Show what I use and get featured on Wes Bos' uses website

Console.log URL for New Drafts

Summary

Add console.log to hygen template so that when you create a new post, it logs a url (maybe even opens it up in the browser) to show that it's ready!

Basic example

Your draft has been started! View at http://localhost:8000/<slug>

Motivation

It'll save a bit of time.

πŸ™…β€β™‚οΈmanually copying is bad
πŸ‘ automating the little bits are good

Add snippets to site

Summary

Similar to notes, but like this

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.

Motivation

Why are we doing this? What use cases does it support? What is the expected outcome?

Support Coding Challenges like freeCodeCamp

Summary

I don't know what this would look like, but I would love to draw inspiration from them and figure out a template/standard/component for adding tests to my blog posts. It could be a lot of fun!

I don't know if Gatsby Recipes would play into this at all but worth investigating as well.

Essentially, make it easy to include challenges in blog posts.

Basic example

A blog post that explains how to do something:

  • teach me about a thing (JavaScript arrays)
  • practice in this challenge
  • test your code to make sure it works!

Motivation

I want to engage with people who come to my blog. Instead of just reading, read learn and then do something!

Add Links to External Posts

Summary

Before this blog, I had written a decent amount of posts elsewhere. It would be great to link those here.

Articles

Basic example

I imagine it looking like my "All Articles" page with a search, a "card" for each post along with an excerpt or summary.

Motivation

It would be a good way to keep everything on one site.

Add "Updated on" to posts

Summary

Brian Lovin wrote about this idea of "Incrementally Correct Personal Websites". I'm thinking about embracing it by adding some piece of information that says "Updated on" to posts.

Basic example

At the top of the post, or bottom of post "Updated on March 22, 2020"

Motivation

Shows that the posts are living and can/could be updated. Also shows my commitment to keeping things accurate and correct.

Site doesn't work in Russia

Describe the bug
The site doesn't work in Russia.

To Reproduce
Steps to reproduce the behavior:

  1. Use a VPN or something to make it look like I'm in Russia??
  2. Visit joeprevite.com

Expected behavior
The site should work in Russia.

Screenshots
image

Additional context
Found by @talentlessguy

Migrate to TypeScript

Summary

Migrate entire codebase to TypeScript

Basic example

N/A

Motivation

  • type safety
  • catch errors before they happen at runtime
  • good practice
  • better documentation/autocomplete
  • fun πŸ˜„

Make Netlify ignore builds for dependabot branches

Summary

Dependabot is getting greedy and stealing all my build minutes. So I'd like to disable Netlify builds for dependabot branches

Basic example

  1. add netlify.toml file
  2. use the ignore block with a unix shell command to ignore those branches

Would probably need to add additional GH Action to build and test project though to make sure things still build.

Motivation

Why are we doing this? What use cases does it support? What is the expected outcome?
Build minutes are scarce and we shouldn't be burning through them so quickly!

Add helpful blocks to posts

Summary

I'd like to add additional types of blocks for my posts. Similar to how Tania uses them in her posts here.

Basic example

image

image

Motivation

Improve the quality and helpfulness of each article. If I can add different types of information to my posts, they will be more helpful and more enjoyable to read.

Website: Open Stats

Summary

It would be cool to share some stats related to my newsletter, like number of subscribers, average open rate, average clicks, average number of emails sent per month.

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.

Motivation

Practicing transparency. Aligns with the idea of open source. Good for the community, fun to share :)

Research good ideas from Twitter thread

Summary

Maggie Appleton shared a bunch of great ideas here.

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.

Motivation

Why are we doing this? What use cases does it support? What is the expected outcome?

Add webmentions to Post

Summary

Add webmentions to blog

Basic example

Follow @dance2die's blog post

Motivation

I want to show the connection between the post someone is reading, and when someone mentioned it on the web (i.e. Twitter). I think it could benefit:

  1. the reader to show what people said about the post
  2. the author (me) to easily see a list of mentions for the post

Add animation to Logo

Summary

Make the JP fade in on load.
Make it spin on hover.

Basic example

Like this

Motivation

Add some flava flav to the site πŸ•Ί

Add "edit on GitHub" link

Summary

Similar to how others with Gatsby blogs (like Tania Rascia), the idea is to have a quick link to edit each post on GitHub. Ideally, it would have a "last updated" with a timestamp as well (maybe using latest commit to file?)

Basic example

See screenshot from blog
edit-example

Motivation

The reason for doing this is to allow readers or myself a way to easily fix typos or suggest edits.

Redo note block

Summary

Brief explanation of the feature.

Make it like prince’s

https://prince.dev/blog/callout

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.

Motivation

Why are we doing this? What use cases does it support? What is the expected outcome?

Add page jump links to posts

Summary

Each heading in a post should be "linkable" meaning a reader can click on it and it will jump there and append it to the URL.

Basic example

2019-12-07 12 38 34

Motivation

It allows readers to be able to share links that jump to specific sections.

Add filters to search for all articles

Summary

It would be nice to be able to filter posts on the /articles page.

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.
image

Motivation

I've written about various topics so it would be nice to filter by those (i.e. TypeScript, Rust, etc.)

Clarify Twitter Card post

hi joe, i was following your post on making a twitter card for your blog. https://joeprevite.com/create-a-twitter-card-for-your-blog.
At the end your said to add meta tag as :
I am a bit confused as to where exactly or in which file do i need to put this. I tried searching in your commit history, but couldn't find!

In the 6th step in the post, I don't say where to put this or where it lives.

Fix Edit on GitHub link

master was hard-coded in the "Edit on GitHub" logic which causes it to break. This can be fixed by updating it to main.

Replace Lighthouse GH action with simpler action

Summary

Add a new GH action that runs yarn install and yarn build and remove the current Lighouse GH action

Basic example

Use the GH action Node.js template. But use yarn install of npm

Motivation

The Lighthouse action has a step called "wait for netlify preview" that consistently fails :( So I think it makes more sense to simplify the process.

Add Line Highlighting

Summary

@maxcell wrote an excellent post about adding line highlighting. I'd like to try and let them know how well it went!

Basic example

See blog post.

Motivation

Allow me to highlight key pieces in code snippets, without having to make them diffs

Test Spellchecker

Summary

Brief explanation of the feature.

http://proselint.com/checks/

Basic example

If the proposal involves a new or changed API, include a basic code example. Omit this section if it's not applicable.

Motivation

Why are we doing this? What use cases does it support? What is the expected outcome?

Set up Lighthouse CI

Describe the bug
Currently, when you open a PR, the CI fails on the first run. This is because the GH action runs before the Netlify deploy is ready.

To Reproduce
Steps to reproduce the behavior:

  1. Open a PR
  2. Watch the GitHub Checks/CI run
  3. See error

Expected behavior
The CI should run after the deploy preview is ready.

Screenshots
N/A

Additional context
N/A

BYOA - Bring your own Analytics?

Summary

I've used GA in the past but trying to move away from it (and it's also not reliable thanks to the ad blockers). I don't want to pay for something (I say that now...). I'm wondering, how difficult can it be to build my own analytics?

Really, all I want to know is:

  • website traffic (page visits)
  • visits to each blog post

Basic example

A page on my website /site or /analytics that displayed a table with:

  • the page/blog post name
  • the number of views

Motivation

It's good to have a metric of some sort πŸ˜„

Add Storybook for JSX Components

Summary

Could be overkill, (honestly probably...) but would be cool to add Storybook and show the different components available for MDX.

Basic example

  • run on localhost, shows components
  • stretch: deployed to storybook.joeprevite.com lol

Motivation

We don't really need it...just a random idea

Add <Quiz /> component

Summary

I want to be able to test myself and readers at the end of blog posts.

Basic example

I imagine the API looking like this:

<Quiz title="JavaScript Arrays">
  <Question 
        title="Arrays are immutable." 
        type="TF"  // truefalse
        answer="F" 
  >
     <Hint>
       Read about `Array` on [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)
     </Hint>
  </Question>
  <Question 
        title="What is the name of the method for filtering an array?" 
        type="MC" // multiplechoice
        options={[".map()", ".pop()", ".push()", ".filter()"]}
        answer={4} // meaning the fourth option
  />
</Quiz>

Motivation

It would be a great way to test my readers and myself!

Can't see name next to logo in light mode

Describe the bug
Name is not appearing with light mode (due to font color)

To Reproduce
Steps to reproduce the behavior:

  1. Go to site
  2. Switch to dark mode
  3. See name
  4. Switch to light mode
  5. See name disappear

Expected behavior
You should be able to see the name "Joe Previte" on both light and dark mode

Screenshots

image

Desktop (please complete the following information):

  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

Found by @Darth-Knoppix

Update Intentional Blog Post

Feedback from @tatianamac

Oh! and also, I might offer mindfulness around tracking percentage; there is no 100%. You may plan to address that, but something to note in an industry full of metric-obsessed folks. :)

Call it out with a <Note /> in the post!

Create section for notes

Summary

I like what Max does with his notes. I know Chris does something similar.

Basic example

Create a section for notes

Motivation

Ability to put things out more quickly. Don't know if it will work that easy but could be worth trying.

Start Dev Server and Open New Post in VSCode

Summary

When creating a new post with yarn g:post, it should automatically start the dev server (yarn dev) if not running and open the new Markdown file in VSCode.

Basic example

if (noDevServer) {
  exec(`yarn dev`)
}

code.open(newfile)

Motivation

Because we want to automate the little things and save some time :)

How to pronounce last name

This has come up multiple times. I need to have a short link or something with a recording on how to pronounce.

Add Contributors

Recognize everyone who played a part in making this come to life.

Dark Mode Issue

I can't remember who said it (someone in the Twitter DMs). But there's some issues with the header color and dark mode. Look into this!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.