muratgozel / MIMEText

RFC-2822, RFC-2045 and RFC-2049 compliant raw email message generator.
https://muratgozel.github.io/MIMEText/
MIT License
82 stars 35 forks source link

export for MIMEMessage #47

Open cloudkite opened 1 year ago

cloudkite commented 1 year ago

Would be nice if there was a way to access the MIMEMessage class from the npm module.

for example:

import MIMEMessage from "mimetext/MIMEMessage"

let envctx = { ... }
let message = new MIMEMessage(envctx)

would be nice for environments like cloudflare workers where node builtins do not exist. Also could have advantages for advanced customisation:

muratgozel commented 9 months ago

hi @cloudkite the library have 3 entrypoints so far, node, gas and browser. and i would like to add support for more environments for sure, i will lookup the cloudflare workers and see if we can add it as an entrypoint. thanks for bringing this up.