summaryrefslogtreecommitdiff
path: root/src (follow)
AgeCommit message (Collapse)AuthorFilesLines
2021-04-06Compiler cleanup (#64)Gravatar Matthew Phillips 3-83/+78
* Compiler cleanup This is general compiler cleanup, especially around the codegen part. Goals here were too: 1. Make it possible to compile HTML recursively (needed for future astro-in-expressions work) by moving that work into its own function. 1. Get rid of collectionItems and have compiling the HTML return just a source string. Also not planned, this change gets rid of the different between components and pages. All Astro components compile to the same JavaScript. * Remove unused node types
2021-04-05Allow no config (#61)Gravatar Drew Powers 2-15/+59
* Allow no config * Update README
2021-04-05[ci] npm run formatGravatar matthewp 3-28/+31
2021-04-05Improve searching for pages (#60)Gravatar Matthew Phillips 3-57/+123
This improves the algorithm for searching for pages. It now works like: 1. If pathname ends with / 1. Look for PATHNAME/index.astro 1. Look for PATHNAME/index.md 1. else 1. Look for PATHNAME.astro 1. Look for PATHNAME.md 1. Look for PATHNAME/index.astro 1. 301 1. Look for PATHNAME/index.md 1. 301 1. 404
2021-04-02Add type declarations (#59)Gravatar Drew Powers 6-26/+42
2021-04-02Fix scoping issues (#58)Gravatar Drew Powers 3-9/+31
2021-04-02Add Tailwind support (#57)Gravatar Drew Powers 3-17/+66
2021-04-02Fix body from being scoped (#56)Gravatar Drew Powers 2-9/+30
2021-04-02Fix React import (#55)Gravatar Drew Powers 4-7/+7
* Fix React import * Change default export * Fix :visible dynamic component * Use colon to alias vue createElement Co-authored-by: Matthew Phillips <matthew@skypack.dev>
2021-04-02Get CSS Modules working in Vue (#53)Gravatar Drew Powers 5-10/+10
2021-04-01Remove errant console.log (#51)Gravatar Matthew Phillips 1-1/+0
2021-04-01[ci] npm run formatGravatar matthewp 3-10/+8
2021-04-01Fix complex MDX parsing (#50)Gravatar Matthew Phillips 6-11/+58
* Fix complex MDX parsing This allows fully MDX support using the micromark MDX extension. One caveat is that if you do something like use the less than sign, you need to escape it because the parser expects these to be tags otherwise. * Move micromark definition
2021-04-01Annoying Lint PR #2 (#47)Gravatar Drew Powers 30-46/+151
2021-04-01Add runtime mode (#48)Gravatar Drew Powers 10-32/+48
2021-03-31Implements import.meta.request (#46)Gravatar Matthew Phillips 1-4/+3
This adds `import.meta.request` to pages (not components).
2021-03-31Support for custom elements (#45)Gravatar Matthew Phillips 6-7/+120
* Support for custom elements Now you can use custom elements like so in Astro components: ```html <script type="module" src="./datepicker.js"> <date-picker></date-picker> ``` These will be resolve relative to the current astro component. In the build these modules are run through the same bundle/minify process as components. * Remove component from public * Formatting * Disable empty fn rule
2021-03-31Implement fallback capability (#44)Gravatar Matthew Phillips 4-13/+36
* Implement fallback capability This makes it possible for a dynamic component to render fallback content on the server. The mechanism is a special `static` prop passed to the component. If `static` is true then the component knows it can render static content. Putting aside the word `static`, is this the right approach? I think giving components the flexibility to make the decision themselves *is* the right approach. However in this case we have a special property that is passed in non-explicitly. I think we have to do it this way because if the caller passes in a prop it will get serialized and appear on the client. By making this something we *add* during rendering, it only happens on the server (and only when using `:load`). Assuming this is the right approach, is `static` the right name for this prop? Other candidates: * `server` That's all I have! * Use `import.meta.env.astro` to tell if running in SSR mode. * Run formatter
2021-03-31Extract Astro styles to external stylesheets (#43)Gravatar Drew Powers 6-82/+92
* Extract Astro styles to external stylesheets * Require relative URLs in Markdown layouts
2021-03-30remove unused fnGravatar Fred K. Schott 1-13/+0
2021-03-30[ci] npm run formatGravatar matthewp 1-1/+1
2021-03-30Add minification (#42)Gravatar Matthew Phillips 1-1/+7
2021-03-30[ci] npm run formatGravatar matthewp 1-2/+2
2021-03-30Resolve component URLs during compilation (#40)Gravatar Matthew Phillips 5-15/+26
Previously dynamic component URLs were being resolved client-side in a weird way that only worked during dev. This change makes them handle during compilation, so it works in both (and improves readability of the dynamic import output).
2021-03-30Fix nested parens bug (#39)Gravatar Drew Powers 2-2/+7
2021-03-30Convert CSS Modules to scoped styles (#38)Gravatar Drew Powers 2-68/+117
* Convert CSS Modules to scoped styles * Update README * Move class scoping into HTML walker * Fix SSR styles test * Fix mustache tags * Update PostCSS plugin name * Add JSDoc comment * Update test
2021-03-30[ci] npm run formatGravatar matthewp 3-20/+17
2021-03-30Add support for doctype (#37)Gravatar Matthew Phillips 5-16/+71
* Add support for doctype * Automatically prepend doctype
2021-03-30[ci] npm run formatGravatar matthewp 4-41/+43
2021-03-30Bundling! 🤘 (#36)Gravatar Matthew Phillips 8-45/+367
* Bundling! 🤘 * Finalize build changes
2021-03-26New hydration methods (#29)Gravatar Nate Moore 6-136/+205
* WIP: new hydration methods * refactor: genericize load/idle/visible renderers * fix: do not pass "data-astro-id" to component * docs: add hydration section to README * docs: update README Co-authored-by: Nate Moore <nate@skypack.dev>
2021-03-26[ci] npm run formatGravatar drwpow 5-19/+13
2021-03-26Fix JSX CSS Modules classes (#31)Gravatar Drew Powers 1-12/+17
2021-03-26Absorb Snowpack config inside Astro (#32)Gravatar Drew Powers 2-3/+7
* Absorb Snowpack config inside Astro * Add basic README * Format tests * Update esbuild * Format tests
2021-03-25Improve styles (#30)Gravatar Drew Powers 1-12/+48
2021-03-25Add React component SSR (#28)Gravatar Drew Powers 3-26/+32
* Add React component SSR * Add React component SSR
2021-03-25First pass at the build (#27)Gravatar Matthew Phillips 11-109/+179
This updates `astro build` to do a production build. It works! No optimizations yet.
2021-03-25add component state, top-level await support (#26)Gravatar Fred K. Schott 41-221/+266
2021-03-24Redesign pages, remove layout nesting (#24)Gravatar Fred K. Schott 7-79/+54
* wip * new svelte-style prop declaration is working * got it working! * revert h changes * format * style lang update
2021-03-24hmx ☞ astro (#22)Gravatar Matthew Phillips 10-44/+46
This changes all hmx files to astro files and updates all code to not reference hmx any more.
2021-03-23import regexGravatar Fred K. Schott 2-1/+9
2021-03-23remove last script tagGravatar Fred K. Schott 2-5/+3
2021-03-23add support for frontmatter scriptsGravatar Fred K. Schott 5-10/+46
2021-03-23Allow HMX components in markdown (#19)Gravatar Matthew Phillips 3-10/+61
* Allow HMX components in markdown This adds support for HMX components in markdown. The mechanism for importing is via frontmatter. We could do this differently (setup script maybe?) but since this was the easiest to implement I thought it was a good first-pass option. * Remove node-fetch from snowpack config * Assert that the runtime is created successfully * Add back in the micromark extension for encoding entities * Encode both codeTextData and codeFlowValue * Install snowpack app's deps
2021-03-23Use <style lang>, add node_module resolution to SassGravatar Drew Powers 1-26/+39
2021-03-23Add support for React components. (#18)Gravatar Matthew Phillips 5-9/+87
* Add support for React components. This adds support for react components via a new `extensions` config in astro.config.mjs. In the future we can extend this to do things like look at the import statements, as Snowpack does. * Fix the tests
2021-03-22[wip] Add styles to Snowpack app (#13)Gravatar Drew Powers 1-5/+9
* Add styles to Snowpack app * Bubble up file build errors * Fix merge error
2021-03-22cleanup new parser handlingGravatar Fred K. Schott 2-22/+14
2021-03-22add typescript support for expressionsGravatar Fred K. Schott 3-25/+53
2021-03-21fix markdown header issueGravatar Fred K. Schott 1-1/+2