[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-73367":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":16,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":23,"hasPages":21,"topics":24,"createdAt":10,"pushedAt":10,"updatedAt":25,"readmeContent":26,"aiSummary":27,"trendingCount":16,"starSnapshotCount":16,"syncStatus":28,"lastSyncTime":29,"discoverSource":30},73367,"Ignite","twostraws\u002FIgnite","twostraws","A static site generator for Swift developers.","",null,"Swift",2250,192,21,13,0,1,8,60.16,"MIT License",false,"main",true,[],"2026-06-12 04:01:09","\u003Cp align=\"center\">\n    \u003Cimg src=\"images\u002Flogo.png\" alt=\"Ignite logo\" width=\"256\" height=\"234\" \u002F>\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FmacOS-14.0+-2980b9.svg\" \u002F>\n    \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fswift-6.0+-8e44ad.svg\" \u002F>\n    \u003Ca href=\"https:\u002F\u002Ftwitter.com\u002Ftwostraws\">\n        \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FContact-@twostraws-95a5a6.svg?style=flat\" alt=\"Twitter: @twostraws\" \u002F>\n    \u003C\u002Fa>\n\u003C\u002Fp>\n\nIgnite is a static site builder for Swift developers, offering an expressive, powerful API to build beautiful websites that work great on all devices.\n\nIgnite doesn't try to convert SwiftUI code to HTML, or simply map HTML tags to Swift code. Instead, it aims to use SwiftUI-like syntax to help you build great websites even if you have no knowledge of HTML or CSS.\n\n\n## Getting started\n\nThe easiest way to get started is to use the Ignite command-line tool included with this package:\n\n1. Run `git clone https:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgnite` to clone this repository to your computer.\n2. Change into the new directory, e.g. `cd Ignite`.\n3. Now run `make` to build the Ignite command-line tool.\n4. Then run `make install` to install the Ignite command-line tool to `\u002Fusr\u002Flocal\u002Fbin`.\n5. If that command fails because of permissions issues, you should run `sudo make install` instead.\n\n> [!Note]\n> To change install directory: `make install PREFIX_DIR=\u002Fmy\u002Finstall\u002Fdir`\n\nOnce that command-line tool is installed, you can run the following command to create a new site called ExampleSite:\n\n```shell\nignite new ExampleSite\n```\n\nOnce installed, the command-line tool is helpful for running a local web server for testing and for building your project.\n\nTo build your example site, run these commands:\n```shell\ncd ExampleSite\nignite build\n```\n\nThat creates a new folder called Build with the site files. Now you can preview it. (For more details on how to build, see \"Using the command-line tool\" below.)\n\n## Important: Previewing your site\n\n> [!Tip]\n> Using the Ignite tool to run a local web server is the best way to preview your site.\n\nOnce you've built your site and are ready to see how it looks, do *not* just double-click one of the files in Finder. This will open the file directly in your browser, which means it won't know how to locate the rest of your site – the stylesheets, JavaScript code, etc – so it will not display correctly.\n\nInstead, the best way to preview your site is using the Ignite CLI tool, which you installed in Getting Started above:\n\n- Run `ignite run --preview` to preview your site and open it in your web browser.\n\nThat will open your web browser straight to your site. You can then return to Xcode and make changes to your site freely – every time you press Cmd+R to build your site, you can refresh your browser to see the changes.\n\n\n## See it in action\n\nThe [IgniteSamples](https:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgniteSamples) repository contains lots of sample code for you to try out – you can see it running here: You can see all the output from this repository running here: \u003Chttps:\u002F\u002Fignitesamples.hackingwithswift.com>.\n\nBasic Ignite code looks similar to SwiftUI code:\n\n```swift\nText(\"Swift rocks\")\n    .font(.title1)\n    \nText(markdown: \"Add *inline* Markdown\")\n    .foregroundStyle(.secondary)\n\nLink(\"Swift\", target: \"https:\u002F\u002Fwww.swift.org\")\n    .linkStyle(.button)\n\nDivider()\n\nImage(\"logo.jpg\")\n    .accessibilityLabel(\"The Swift logo.\")\n    .padding()\n```\n\nBut it also includes a range of more advanced controls such as dropdown buttons:\n\n```swift\nDropdown(\"Click Me\") {\n    Link(\"Accordions\", target: AccordionExamples())\n    Link(\"Carousels\", target: CarouselExamples())\n    Divider()\n    Text(\"Or you can just…\")\n    Link(\"Go back home\", target: \"\u002F\")\n}\n.role(.primary)\n```\n\n![A dropdown button showing links, a divider, and some text.](images\u002Fdropdown.png)\n\nIt includes accordions that show or hide items based on what is selected:\n\n```swift\nAccordion {\n    Item(\"First\", startsOpen: true) {\n        Text(\"This item will start open by default.\")\n    }\n\n    Item(\"Second\") {\n        Text(\"This is the second accordion item.\")\n    }\n\n    Item(\"Third\") {\n        Text(\"This is the third accordion item.\")\n    }\n}\n.openMode(.individual)\n```\n\n![An accordion of three items, where the first one is open.](images\u002Faccordions.png)\n \nIt has automatic code syntax highlighting for a dozen languages:\n\n```swift\nCodeBlock(.swift) { \"\"\"\nstruct ContentView: View {\n    var body: some View {\n        Text(\"Hello, Swift!\")\n    }\n}\n\"\"\" }\n```\n\n![Swift code with syntax highlighting.](images\u002Fcode.png)\n\nPlus carousels, badges, alerts, tables, and so much more.\n\nThere is a separate repository called [IgniteSamples](https:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgniteSamples), which provides sample code for a wide variety of protocols, elements, and modifiers used by Ignite.\n\nIf you're looking for code to help you get started, that's the best place – you can build that site and run it locally, the copy and paste any code you want to try.\n\n\n## Folder structure\n\nIgnite sites are just Swift package, but they use a specific folder structure to help build your site effectively.\n\n- **Assets**: This is where your custom site assets should be placed, using whatever subfolders you want.\n- **Build**: This is created automatically by Ignite whenever you build your site. Do not place important information here, because it will be deleted on your next build.\n- **Content:** This is where you want to place any Markdown files for posts you want, again using any subfolder structure you want. (Optional)\n- **Includes:** This is where you place any custom HTML you've written that you want to include. (Optional)\n- **Sources:** This is where you'll place all your Swift code for your site, using any subfolder structure that suits you.\n\nThis folder structure is already in place in the [Ignite Starter Template](https:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgniteStarter) repository, and I recommend you start with that.\n\nAlternatively, you can bring Ignite into an existing project using Swift Package Manager by adding a package dependency for \u003Chttps:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgnite>.\n\nOnce that completes, import Ignite into your Swift code wherever needed:\n\n```swift\nimport Ignite\n```\n\n## Create a layout to render Markdown files\n\nAdding Markdown files to **Content** will render these to HTML pages and include them in **Build** with their respective folder structure, minus the **Content** part.\n\nFor example, adding a new file called `apps.md` to **Content** means having this folder structure:\n\n```bash\n├── Content\n│   └── apps.md\n```\n\nAnd it results in this **Build** structure:\n\n```bash\n├── Build\n│   ├── …\n│   ├── apps\n│   │   └── index.html\n│   ├── …\n```\n\n**A precondition for this to work is to have a layout available to render your content.** If you don't have a valid layout in place, Ignite will issue a warning saying \"Your site must provide at least one layout in order to render Markdown.\"\n\nYou can create custom layouts for articles by making types conform to the `ArticlePage` protocol, which will automatically be given an `article` property to access the content it is displaying. For example:\n\n```swift\nimport Foundation\nimport Ignite\n\nstruct CustomArticleLayout: ArticlePage {\n    var body: some HTML {\n        Text(article.title)\n            .font(.title1)\n\n        if let image = article.image {\n            Image(image, description: article.imageDescription)\n                .resizable()\n                .cornerRadius(20)\n                .frame(maxHeight: 300)\n        }\n\n        if let tags = article.tags {\n            Section {\n                Text(\"Tagged with: \\(tags.joined(separator: \", \"))\")\n\n                Text(\"\\(article.estimatedWordCount) words; \\(article.estimatedReadingMinutes) minutes to read.\")\n            }\n        }\n\n        Text(article.text)\n    }\n}\n```\n\nOnce you've defined a custom layout, you should add it to your `Site` struct. This can be done by adding this new layout to the `articlePages` property of the site, like this:\n\n```swift\nstruct ExampleSite: Site {    \n    var name = \"Hello World\"\n    var url = URL(static: \"https:\u002F\u002Fwww.example.com\")\n\n    var homePage = Home()\n    var layout = MyLayout()\n\n    \u002F* This part adds the custom layout *\u002F\n    var articlePages: [any ArticlePage] {\n        CustomArticleLayout()\n    }\n}\n```\n\nThe `Site` protocol provides sensible defaults for most properties, allowing you to focus on implementing only the customizations your site needs. As shown in the above, only a few properties like `name`, `url`, `homePage`, and `layout` require explicit implementation.\n\n## Using the command-line tool\n\nOnce you have installed the Ignite command-line tool from this repository, you can use it in various ways.\n\nFirst, you can create new site like this:\n\n```shell\nignite new YourSite\n```\n\nWhen that completes, it will tell you the commands to use to open your new site for editing in Xcode:\n\n```shell\ncd YourSite\nopen Package.swift\n```\n\n> [!Tip]\n> If you want to build with Xcode, go to the Product menu and choose Destination > My Mac.\n\nBack in your terminal window, once you have run that `cd` command the current working directory of your terminal is your website's directory. This means you can run the following command to build your site, rather than using Xcode:\n\n```shell\nignite build\n```\n\nThat will convert all your Swift code to HTML in your **Build** folder. \n\nYou can also run this command:\n\n```shell\nignite run --preview\n```\n\nThat will launch a local web server you should use to preview your site, and also open it in your browser. If you're working in Xcode, you can continue performing builds as normal then refresh your browser to see your changes.\n\n> [!Tip]\n> The Ignite command-line tool has various configuration options available. Run `ignite help` to get general help, or add `help` before a subcommand to get further details, e.g. `ignite help run`.\n\n\n## Websites made with Ignite\n\n| Website                | Repository                                |\n|------------------------|-------------------------------------------|\n| [Lighting Ignite on Fire](https:\u002F\u002Fjptoro.dev\u002Flighting-ignite-on-fire\u002F) | [GitHub](https:\u002F\u002Fgithub.com\u002FJPToroDev\u002FLighting-Ignite-on-Fire) |\n| [jcalderita Portfolio](https:\u002F\u002Fjcalderita.com) | [GitHub](https:\u002F\u002Fgithub.com\u002Fjcalderita\u002Fportfolio-web-ignite) |\n| [Photo Club Hub](https:\u002F\u002Fwww.fcDeGender.nl\u002Fclubs) | [GitHub](https:\u002F\u002Fgithub.com\u002Fvdhamer\u002FPhoto-Club-Hub-HTML) |\n| [sookim-1's T.W.L](https:\u002F\u002Fsookim-1.github.io) | [GitHub](https:\u002F\u002Fgithub.com\u002Fsookim-1\u002Fblog-website) |\n| [try! Swift Tokyo](https:\u002F\u002Ftryswift.jp\u002Fen\u002F) | [GitHub](https:\u002F\u002Fgithub.com\u002Ftryswift\u002Ftry-swift-tokyo) |\n| [Tomo Codes](https:\u002F\u002Ftomo.codes) | [GitHub](https:\u002F\u002Fgithub.com\u002FTomaszLizer\u002FTomoCodes) |\n| [Ryan Token](https:\u002F\u002Fwww.ryantoken.com) | [GitHub](https:\u002F\u002Fgithub.com\u002Fr-token\u002Fryantoken.com-v4-ignite) |\n| [Codaglot](https:\u002F\u002Fcodaglot.skjorn.name) | [GitHub](https:\u002F\u002Fgithub.com\u002Fskjorn\u002Fcodaglot-showcase) |\n\n\n## Contributing\n\nI welcome all contributions, whether that's adding new tests, fixing up existing code, adding comments, or improving this README – everyone is welcome!\n\n- You must comment your code thoroughly, using documentation comments or regular comments as applicable.\n- Please ensure you run SwiftLint in the Sources directory, and fix all outstanding issues.\n- All code must be licensed under the MIT license so it can benefit the most people.\n- Ensure you build IgniteSamples using your modified copy of Ignite, and compare it to [the live version](https:\u002F\u002Fgithub.com\u002Ftwostraws\u002FIgniteSamples).\n- If you create a new element, please consider adding it to the IgniteSamples repository, so folks can see it more easily.\n\n\n## Credits\n\nIgnite is an open-source project with many contributors, including Paul Hudson, JP Toro, Henrik Christensen, Michael Freiwald, and Jobert Sá.\n\nAll contributions are welcome, but please ensure you abide by the [Code of Conduct](CODE_OF_CONDUCT.md).\n\n\n## License\n\nMIT License.\n\nCopyright (c) 2024 Paul Hudson.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and\u002For sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\nIgnite was originally created by [Paul Hudson](https:\u002F\u002Ftwitter.com\u002Ftwostraws), who writes [free Swift tutorials over at Hacking with Swift](https:\u002F\u002Fwww.hackingwithswift.com). It’s available under the MIT license, which permits commercial use, modification, distribution, and private use.\n\n\n\u003Cp align=\"center\">\n    \u003Ca href=\"https:\u002F\u002Fwww.hackingwithswift.com\u002Fplus\">\n    \u003Cimg src=\"https:\u002F\u002Fwww.hackingwithswift.com\u002Fimg\u002Fhws-plus-banner@2x.jpg\" alt=\"Hacking with Swift+ logo\" style=\"max-width: 100%;\" \u002F>\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">&nbsp;\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n    \u003Ca href=\"https:\u002F\u002Fwww.hackingwithswift.com\">\u003Cimg src=\"https:\u002F\u002Fwww.hackingwithswift.com\u002Fimg\u002Fhws-button@2x.png\" alt=\"Hacking with Swift logo\" width=\"66\" height=\"75\" \u002F>\u003C\u002Fa>\u003Cbr \u002F>\n    A Hacking with Swift Project\n\u003C\u002Fp>\n","Ignite 是一个面向 Swift 开发者的静态网站生成器。它提供了一个表达力强且功能强大的 API，使得开发者能够利用类似 SwiftUI 的语法构建美观且响应式的网站，无需了解 HTML 或 CSS。该项目支持 macOS 14.0+ 和 Swift 6.0+，并采用 MIT 许可证发布。通过其命令行工具，用户可以轻松创建新项目、启动本地服务器进行预览以及构建最终的网站文件。Ignite 特别适合那些希望利用自己在 Swift 方面的知识来快速搭建个人博客、文档页面或其他类型静态网站的技术人员使用。",2,"2026-06-11 03:45:11","high_star"]