-
Notifications
You must be signed in to change notification settings - Fork 42
[C4GT] Plugins #122
Description
Project Details
Doc Generator is a tool to create PDFs from a variety of formats. It is used extensively in our programs where we need to share a PDF report of some data. Be it class reports, student reports or usage numbers of our solutions.
Templater a REST API service that can store, manage and render templates. A Template is like a well-defined format in which data can be entered. The output generated is according to the format defined in the template. Templater helps us simplify and enhance this process by providing multiple services such as Data transformation, Lambda API, Templater Playground, Support for multiple engines, etc.
Currently doc generator has its own backend. Moving to Templater as a backend will allow us to benefit from all the development happening at Templater in real time. It would also allow us to spend time on features other than input processing which would be powered by Templater.
Plugin
Consists of Input (Template Type) + Output (Format), plugin can support transforming a set of template types into a set of output formats.
Plugin Registry
Plugin registry holds these details about plugins, these are used to create jobs for generating/transforming templates.
- Input
- Output
- Transformer
Combination Matrix
How to read => Column is input, row in output
| Docsx | Image | Draw.io | Excalidraw | Mermaid | ||
|---|---|---|---|---|---|---|
| ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | |
| Docsx | ❌ | ✅ | ❌ | |||
| Image | ✅ | ✅ | ✅ | |||
| Draw.io | ❌ | ❌ | ❌ | |||
| Excalidraw | ❌ | ❌ | ❌ | |||
| Mermaid | ❌ | ❌ | ❌ |
- Google Docs = Docx
- PDFMake == PDF
References
Features to be implemented
Plugins as a framework similar to how VS Code allows for creating extensions.
What exists
The feature doesn't exist right now.
What needs to be built
- EJS Input Plugin #79
- Jinja Input Plugin #80
- JSTL Input Plugin #81
- PDF Make #82
- Google Doc #83
- Markdown #84
- URL - HTML (Dynamic), Markdown, ... #85
- drawio, excalidraw, ... #86
- Mermaid #87
- Image (base64) output plugin #88
- HTML (string) #89
- PDF (base64) #90
- QrCode #91
- Shortened URL (for any of 1, 2, 3, or 4) #92
- Web Page (for any of 1, 2, 3, or 4) #93
Learning Path
Complexity
High
Skills Required
HTML, Python, Typescript, NestJS.
Name of Mentors:
Project size
8 Weeks
Out of Scope
Milestones
- Understanding the requirements
- Understanding Doc Generator
- Understanding Templater
- Planning elements of doc generator that would move to templater
- Define approaches of the implementation
- Implement backend with templater
- Write tests to verify functionality
C4GT
This issue is nominated for Code for GovTech (C4GT) 2023 edition.
C4GT is India's first annual coding program to create a community that can build and contribute to global Digital Public Goods. If you want to use Open Source GovTech to create impact, then this is the opportunity for you! More about C4GT here: https://codeforgovtech.in/
