Inicie su proyecto con este modelo de blog. Este starter se entrega con los archivos de configuración principales de Gatsby que puede necesitar para comenzar a funcionar rápidamente con el generador de aplicaciones ultrarrápido para React. .
¿Tienes otra idea más concreta? Quizás quieras echar un vistazo a nuestra vibrante colección de official and community-created starters.
-
Create a Gatsby site.
Use the Gatsby CLI (install instructions) to create a new site, specifying the blog starter.
# create a new Gatsby site using the blog starter gatsby new my-blog-starter https://github.com/gatsbyjs/gatsby-starter-blog
-
Start developing.
Navigate into your new site’s directory and start it up.
cd my-blog-starter/ gatsby develop
-
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-blog-starter
directory in your code editor of choice and editsrc/pages/index.js
. Save your changes and the browser will update in real time!
Deploy this starter with one click on Netlify:
Un vistazo rápido a los archivos y directorios de nivel superior que verá en un proyecto típico de Gatsby .
.
├── node_modules
├── src
├── .gitignore
├── gatsby-browser.js
├── gatsby-config.js
├── gatsby-node.js
├── gatsby-ssr.js
├── LICENSE
├── package.json
└── README.md
-
/node_modules
: Este directorio contiene todos los módulos de código de los que depende su proyecto (paquetes npm) que se instalan automáticamente. -
/src
: Este directorio contendrá todo el código relacionado con lo que verá en la interfaz de su sitio (lo que verá en el navegador), como el encabezado de su sitio o una plantilla de páginasrc
is a convention for “source code”. -
.gitignore
: This file tells git which files it should not track / not maintain a version history for. -
gatsby-browser.js
: Este archivo es donde Gatsby espera encontrar cualquier uso del Gatsby browser APIs (if any). (Si alguna). Estos permiten la personalización/extensión de la configuración predeterminada de Gatsby que afecta la navegación. -
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). -
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. -
gatsby-ssr.js
: Este archivo es donde Gatsby espera encontrar cualquier uso del Gatsby server-side rendering APIs (if any). Estos permiten la personalización de la configuración predeterminada de Gatsby que afecta la representación del lado del servidor.. -
LICENSE
: Este iniciador de Gatsby tiene la licencia 0BSD. Esto significa que puede ver este archivo como marcador de posición y reemplazarlo con su propia licencia. -
package.json
: Un archivo de manifiesto para proyectos Node.js, que incluye cosas como metadatos (el nombre del proyecto, autor, etc.). Este manifiesto es cómo npm sabe qué paquetes instalar para su proyecto. -
README.md
: Un archivo de texto que contiene información de referencia útil sobre su proyecto.
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.
Build, Deploy, and Host On Netlify
The fastest way to combine your favorite tools and APIs to build the fastest sites, stores, and apps for the web. And also the best place to build, deploy, and host your Gatsby sites.