{"id":20788741,"url":"https://github.com/lawfulgood/simplates","last_synced_at":"2026-05-27T12:32:10.933Z","repository":{"id":57548178,"uuid":"81660099","full_name":"LawfulGood/simplates","owner":"LawfulGood","description":null,"archived":false,"fork":false,"pushed_at":"2017-11-05T00:25:11.000Z","size":32,"stargazers_count":1,"open_issues_count":3,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-18T10:20:43.382Z","etag":null,"topics":["elixir","templates"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LawfulGood.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-02-11T15:01:51.000Z","updated_at":"2017-02-13T05:39:57.000Z","dependencies_parsed_at":"2022-09-26T18:41:04.031Z","dependency_job_id":null,"html_url":"https://github.com/LawfulGood/simplates","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LawfulGood%2Fsimplates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LawfulGood%2Fsimplates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LawfulGood%2Fsimplates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LawfulGood%2Fsimplates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LawfulGood","download_url":"https://codeload.github.com/LawfulGood/simplates/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243132104,"owners_count":20241344,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["elixir","templates"],"created_at":"2024-11-17T15:16:12.462Z","updated_at":"2025-12-16T10:54:29.771Z","avatar_url":"https://github.com/LawfulGood.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Simplates for Elixir\n[![Build Status](https://travis-ci.org/LawfulGood/simplates.svg?branch=master)](https://travis-ci.org/LawfulGood/simplates)\n[![Coverage Status](https://coveralls.io/repos/github/LawfulGood/simplates/badge.svg?branch=master)](https://coveralls.io/github/LawfulGood/simplates?branch=master)\n\nSimplates are a file format for server-side web programming. Used currently in [Infuse](https://github.com/LawfulGood/infuse).\n\nThis repository is my future spec for [simplates.org](http://simplates.org/)\n\n## Why Simplates? \nMixing code into templates leads to unmaintainable spaghetti. On the other \nhand, putting closely-related templates and code in completely separate \nsubdirectories makes it painful to switch back and forth.\n\nSimplates improve web development by bringing code and templates as close \ntogether as possible, _without_ mixing them.\n\n## What does a Simplate look like?\nHere's an example: \n```\n\u003cscript\u003e\n  program = \"hellö\"\n  excitement = :rand.uniform(100)\n\u003c/script\u003e\n\n\u003ctemplate type=\"text/html\" via=\"EEx\"\u003e\n  \u003ch1\u003e\u003c%= hello %\u003e, program, my favorite number is \u003c%= num %\u003e\u003c/h1\u003e\n\u003c/template\u003e\n```\n\n## Installation\n\n  1. Add `simplates` to your list of dependencies in `mix.exs`:\n\n    ```elixir\n    def deps do\n      [{:simplates, \"~\u003e 0.4.0\"}]\n    end\n    ```\n\n  2. Ensure `simplates` is started before your application:\n\n    ```elixir\n    def application do\n      [applications: [:simplates]]\n    end\n    ```\n  \n  3. Create \u0026 render like so\n  \n    ```elixir\n    page = Simplates.Simplate.create_from_string(\"\u003ctemplate\u003e\\nHello\\n\u003c/template\u003e\")\n\n    {output, _} = Simplates.Simplate.render(page, \"text/plain\")\n    ```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flawfulgood%2Fsimplates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flawfulgood%2Fsimplates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flawfulgood%2Fsimplates/lists"}