GithubHelp home page GithubHelp logo

7ty's Introduction

7ty

7ty is a Static Site Generator that uses Svelte for templating.

Documentation

Installation

npm init @jamcart/7ty new-folder

Features

  • Svelte: Write everything as single file components.
  • File based routing: Simple websites can be written with no configuration needed at all.
  • 0kb JS: Only includes JavaScript on pages that absolutely need it.
  • Partial Hydration: Designate which components need to be interactive and the JavaScript will be compiled just for those.
  • Rollup Based: Seamlessly integrates with the existing Rollup ecosystem.

7ty's People

Contributors

waltzingpenguin 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

7ty's Issues

Duplicate stylesheet link tags

Can't put exactly my finger on this but when using template and adding new routes that use shared layout (_layout.svelte) which has hydrated component (_saved-items.svelte) then related generated html files will contain duplicate styleheet link tags

...
  <link rel="stylesheet" href="/c8d0455f.css">
  <link rel="stylesheet" href="/aa89a59a.css">
  <link rel="stylesheet" href="/c8d0455f.css">  
...

It can probably be fixed at earlier stage but I filtered out duplicates in src/build/html.js/writeHTML()

- const stylesheet_links = stylesheets.map(href => `<link rel="stylesheet" href="/${ href }" />`).join('\n')
+ const stylesheet_links = stylesheets.filter((v,i) => stylesheets.indexOf(v) === i).map(href => `<link rel="stylesheet" href="/${ href }" />`).join('\n')

Other than that, really great tool!

Dynamic routes in public folder

Is there any reason behind including dynamic route folders (as [slug] with index-[hash].js in template project) to public folder on production build, I think these are not used in production at all?

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.