???? ??? ??? ???? ??
npm create astro@latest ---??? ???
??? ?? ?????
npm ?? ??
Astro 5??? ??? ?? ? ?? ???? ???? ???? ???? ??? ??? API? ?? ???? ? ?? ??? Content Layer API? ???????.
? API? ?? ???? ??, ?? API, ??? ?? ???(CMS) ? ??? ??? ???? ??? ? ?? ???? ?????. ?? ???? ???? ???? "???"? ???? ???? ????? ???? ??? ? ????. ?? Content Layer API? ???? ?? ???? ??? ???? ?? ??? ???? ??? ???? ????.
https://astro.build/blog/astro-5/
dev.to ???? ???? ???? Astro? Content Layer API
Astro? Content Layer API? ???? dev.to ???? ???? ??? ? ????. dev.to? ?? ?? ??? ??? ?? API? ???? Astro? ??? ???? ???? ???? ??? ?? ??? ?? ? ????.
?? ????? ?? ??? ????.
1. dev.to API? ?? ??? ??
DEV_TO_API_URL=https://dev.to/api/ DEV_API_KEY=tu_clave_de_api
2. ???? ???? ??? ????.
????? src/lib/ ???? ?? ??? ???? getArticles.js ??? ???? ???? ?????.
const { DEV_API_KEY, DEV_TO_API_URL } = import.meta.env; export async function fetchArticles() { const res = await fetch(`${DEV_TO_API_URL}articles/me/published`, { headers: { "api-key": DEV_API_KEY, }, }); const data = await res.json(); return data; }
3. Astro?? ??? ??
src/content.config.ts?? Content Layer API? ???? dev.to ???? ?? ???? ?????.
import { glob } from 'astro/loaders'; import { defineCollection, z } from 'astro:content'; import { fetchArticles } from "../lib/getArticles"; const blog = defineCollection({ // Load Markdown and MDX files in the `src/content/blog/` directory. loader: glob({ base: './src/content/blog', pattern: '**/*.{md,mdx}' }), // Type-check frontmatter using a schema schema: z.object({ title: z.string(), description: z.string(), // Transform string to Date object pubDate: z.coerce.date(), updatedDate: z.coerce.date().optional(), heroImage: z.string().optional(), }), }); const devTo = defineCollection({ loader: async () => { const articles = await fetchArticles(); return articles.map((article) => ({ id: article.id.toString(), slug: article.slug, body: article.body_markdown, data: { title: article.title, date: new Date(article.published_at), tags: article.tag_list, summary: article.description, image: article.social_image, }, })); }, }); export const collections = { blog, devto };
? ??? ??? ??.to? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

??? ??











javascriptisIdealforwebDevelopment, whilejavasuitslarge-scaleapplicationsandand development

JavaScript?? ?? ?? ?? (//) ?? ?? ?? ?? (//)? ???? ??? ?? ? ???? ?? ??? ?? ????. 1. ??? ??? ??? ?? ?? ?? ??? ??????. 2. ??? ??? ?? ?? ?? ??? ??????. 3. ?? ???? ???? ??????. 4. ???? ??? ?????. 5. ??? ??? ????? ?????? ??? ??????. ??? ?? ???? ???? ??? ???? ?? ??? ?? ? ? ????.

?, JavaScriptCommentsArenecessaryandshouldEfficively.

Java ? JavaScript? ?? ?? ????? ??? ?? ?? ?? ???? ????? ?????. Java? ??? ? ??? ?????? ??? ???? JavaScript? ?? ? ??? ??? ?????.

JavaScriptCommentsareEnsentialformaining, ?? ? ???? 1) Single-LinecommentsERUSEDFORQUICKEXPLANATIONS.2) Multi-linecommentSexplaincleClexLogicOrprovidedEdeDDocumentation.3) inlineecommentsClarifySpecificPartSofcode.bestPractic

CommentAreCrucialInjavaScriptFormainingClarityandFosteringCollAboration.1) 1) thehelpindebugging, onboarding ? undervestandingStandingCodeevolution.2) awithy-linecommentsforquickexplanationsandmulti-linecommentsfordeTailedDescriptions.3) BestPricticesInclud

javascriptassseveralprimitavivedatatatatatypes : ??, ???, ??, ????, null, ??, andbigint, andnon-primitiveTypes like-rucial-writingefficial, numberusesa64-bitformat, leadingtofloating-pointsli

JavaScriptIspreferredforwebDevelopment, whithjavaisbetterforlarge-scalebackendsystemsandandandoidapps.1) javascriptexcelsincreatinginteractivewebexperiences withitsdynatureanddommanipulation.2) javaoffersstrongtypingandobject-Orientededededededededededededededededdec
