Plugin description
On Android, the native.showPopup("mail", options) opens a general system Share Sheet. I needed a plugin that opens a pre-populated email, and here's it.
Usage example:
local emailpopup = require("plugin.emailpopup")
emailpopup.show({
to = "support@example.com", -- string or array of strings
cc = { "cc1@example.com", "cc2@example.com" },
bcc = "bcc@example.com",
subject = "Hello from my app",
body = "Message body here.",
isBodyHtml = false,
attachment = {
baseDir = system.DocumentsDirectory,
filename = "log.txt",
type = "text/plain",
},
})
I created an open-source repo already, but it seems like it has to be hosted under the solar2d org. Attaching it here in case you'd like to review:
https://github.com/Idlevelopment/com.idleveloping-plugin.emailpopup
Desired publisher Id
com.idleveloping
Your plugin name
plugin.emailpopup
Terms and conditions
Plugin description
On Android, the
native.showPopup("mail", options)opens a general system Share Sheet. I needed a plugin that opens a pre-populated email, and here's it.Usage example:
I created an open-source repo already, but it seems like it has to be hosted under the solar2d org. Attaching it here in case you'd like to review:
https://github.com/Idlevelopment/com.idleveloping-plugin.emailpopup
Desired publisher Id
com.idleveloping
Your plugin name
plugin.emailpopup
Terms and conditions