{"id":24574917,"url":"https://github.com/kode-rex/mustache-reports","last_synced_at":"2025-04-23T15:21:53.565Z","repository":{"id":22783749,"uuid":"97307795","full_name":"Kode-Rex/Mustache-Reports","owner":"Kode-Rex","description":"Reference implementation of clean architecture using docx templater to render docx to pdf reports. ","archived":false,"fork":false,"pushed_at":"2023-01-06T20:21:09.000Z","size":31183,"stargazers_count":4,"open_issues_count":12,"forks_count":2,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-13T00:29:10.253Z","etag":null,"topics":["clean-architecture","docx","docxtemplater","dotnetcore","libreoffice","pdf","reporting"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Kode-Rex.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-07-15T10:09:27.000Z","updated_at":"2022-11-03T16:53:10.000Z","dependencies_parsed_at":"2023-01-13T22:12:59.049Z","dependency_job_id":null,"html_url":"https://github.com/Kode-Rex/Mustache-Reports","commit_stats":null,"previous_names":["kode-rex/mustache-reports"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kode-Rex%2FMustache-Reports","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kode-Rex%2FMustache-Reports/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kode-Rex%2FMustache-Reports/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kode-Rex%2FMustache-Reports/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Kode-Rex","download_url":"https://codeload.github.com/Kode-Rex/Mustache-Reports/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250457809,"owners_count":21433740,"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":["clean-architecture","docx","docxtemplater","dotnetcore","libreoffice","pdf","reporting"],"created_at":"2025-01-23T21:53:58.668Z","updated_at":"2025-04-23T15:21:53.530Z","avatar_url":"https://github.com/Kode-Rex.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Mustache-Reports\nAn example of using the mustache reports server code base to generate reports in docx using node and LibreOffice to convert to PDF.\n\n_You will need to make sure both node and libreoffice 5 are installed on your computer to run this example._\n\n_This example is rough and ready, please log an issue if you require assistance._\n\n_There are now nuget packages which contain the core report rendering logic, removing the need to manually manage node packages in your solution_. \n\nThe word file generations happens using [docx-templater](https://docxtemplater.com/) and [xlsx-template](https://www.npmjs.com/package/xlsx-template). It is written in node and uses mustache templating to populate the report.\nYou will need to model your report data in JSON for the templating to work, and because docx-templater is so awesome you can use [angular expression](https://docxtemplater.readthedocs.io/en/latest/angular_parse.html) to modify reporting data at runtime. It is unknown if xlsx-template also supports angular expressions, if not I will add it soon.\n\nHave a look at _reportRender.js_ ReportRender.prototype.configureAngularExpressions method - you can add your own customer angular expressions here.  \n_Please note there are currently plans to abstract this allowing your to specify your own angular expressions file without needing to modify the core package. This is one of my main focuses_\n\nI have also added a custom image handling code to allow for base64 encoded image data to be part of the JSON payload - have a look at _reportRender.js_ ReportRender.prototype.getOptions method for more detail.\n_Please note this is now a paid for feature of docx-templater, good thing we got the last version of the open source image module_\n\nThis example makes use of TddBuddy's Clean Architecture and Synchronous Process Execution packages. \n \n+ Synchronous Process Runner - DotNetCore\n   - Install-Package TddBuddy.Synchronous.Process.Runner.DotNetCore\n   - Source @ https://github.com/StoneAgeTechnologies/Synchronous-Process-Runner-DotNetCore\n \n+ Clean Architecture Domain - DotNetCore\n   - Install-Package TddBuddy.CleanArchitecture.Domain.DotNetCore\n   - Source @ https://github.com/StoneAgeTechnologies/CleanArchitecture-DotNetCore.git\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkode-rex%2Fmustache-reports","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkode-rex%2Fmustache-reports","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkode-rex%2Fmustache-reports/lists"}