{"id":20573168,"url":"https://github.com/ashmadev/sexymail","last_synced_at":"2025-04-14T17:24:04.389Z","repository":{"id":219092116,"uuid":"748116227","full_name":"AshmaDev/sexymail","owner":"AshmaDev","description":"A simple Node.js tool for generating sexy emails","archived":false,"fork":false,"pushed_at":"2024-06-09T16:51:55.000Z","size":513,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-28T06:04:29.307Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/AshmaDev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-01-25T10:03:11.000Z","updated_at":"2024-11-21T12:13:33.000Z","dependencies_parsed_at":"2024-02-17T19:30:41.652Z","dependency_job_id":"d82465c6-2c8c-4cf4-9d77-492ee3fa4524","html_url":"https://github.com/AshmaDev/sexymail","commit_stats":null,"previous_names":["ashmadev/sexymail"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AshmaDev%2Fsexymail","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AshmaDev%2Fsexymail/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AshmaDev%2Fsexymail/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AshmaDev%2Fsexymail/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AshmaDev","download_url":"https://codeload.github.com/AshmaDev/sexymail/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248924549,"owners_count":21184102,"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":[],"created_at":"2024-11-16T05:25:55.641Z","updated_at":"2025-04-14T17:24:04.362Z","avatar_url":"https://github.com/AshmaDev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SexyMail\n\n\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"img/sexymail.png\" alt=\"Sexy Mail\" width=\"250\" height=\"250\"\u003e\n  \u003cp\u003eA simple Node.js tool for generating sexy emails\u003c/p\u003e\n\u003c/div\u003e  \n\n## Getting Started\n\nThis package includes a simple HTML generator that allows you to create a sexy email.  \n\n### Installation\n\n```sh\nnpm i sexymail\n```\n\n### Configuration  \n\n```ts\nimport { SexyMail } from \"sexymail\";\n\nconst sexyMail = new SexyMail({\n    logo: \"YOUR_LOGO_URL\",\n    colors: {\n        headingText: \"#000000\", // heading text color\n        primaryText: \"#ffffff\", // buttons text color\n        background: \"#f8f8f8\", // background color\n        foreground: \"#ffffff\", // foreground color\n        secondary: \"#5a5a5a\", // secondary theme color\n        primary: \"#000000\", // buttons background color\n        text: \"#5a5a5a\", // body text color\n    },\n    footer: \"optional footer text\"\n});\n``` \n\n### Options\n\nWhat options are available for formatting messages?  \n\nType  | Value  | Description\n-------------  | -------------  | ------------- \nheader  | string  | Returns formatted header\ntext  |  string  | Returns formatted paragraph\nlink  | { text: string, url: string } | Returns formatted anchor\ncode  | string  | Returns formatted code (number/string)\nlist  | { items: ListItem[], summary: SummaryItem[] }  | Returns formatted list of items / summary\nblank  | string  | Returns unstyled text\n  \n### Example verification message:   \n```ts\nconst htmlMsg = sexyMail.generate([\n  {\n    type: \"header\",\n    value: \"Verification link\",\n  },\n  {\n    type: \"text\",\n    value: \"Click the link below to verify your account!\",\n  },\n  {\n    type: \"link\",\n    value: { text: \"Click here\", url: \"LINK_URL\" },\n  },\n]);\n```  \n  \n### Example confirmation message with list:   \n```ts\nconst htmlMsg2 = sexyMail.generate([\n  {\n    type: \"header\",\n    value: \"Confirmation of purchase\",\n  },\n  {\n    type: \"text\",\n    value: \"Below you will find a list of your purchases:\",\n  },\n  {\n    type: \"list\",\n    value: {\n      items: [\n        {\n          img: \"ITEM_IMAGE_1\",\n          name: \"ITEM_NAME_1\",\n          quantity: \"ITEM_QUANTITY_1\",\n          price: \"ITEM_PRICE_1\",\n        },\n        {\n          img: \"ITEM_IMAGE_2\",\n          name: \"ITEM_NAME_2\",\n          quantity: \"ITEM_QUANTITY_2\",\n          price: \"ITEM_PRICE_2\",\n        },\n      ],\n      summary: [\n        {\n          name: \"SUMMARY_TITLE_1\",\n          value: \"SUMMARY_TEXT_1\",\n        },\n        {\n          name: \"SUMMARY_TITLE_2\",\n          value: \"SUMMARY_TEXT_2\",\n        },\n      ],\n    },\n  },\n]);\n```\n\nYou can now use your `htmlMsg` as a email message. \n\nYou have complete freedom in building ejaculate argument object. You can use the components in any number and order.\n\n\n## License\n\nThis project is licensed under the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashmadev%2Fsexymail","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fashmadev%2Fsexymail","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fashmadev%2Fsexymail/lists"}