Advice for a new addon author

Hi everyone! I’m excited to start writing a new RW addon for my new project, Emporter.app. The short version is that the addon would make it possible for weavers to instantly share their work (anywhere) before deploying, and get feedback before publishing.

What advice would you have for someone writing their first addon? I want to make sure to implement something that the community will love.

Thanks!

2 Likes

Oh, that’s awesome! I tweeted about your app yesterday!!!
https://twitter.com/isaiah/status/1131548737267032064

  • I think even without building a dedicated add-on, it might be easy to accomplish. RW can preview to any browser. If you just set-up Emporter as the designated browser, then previewing to that would automatically send Emporter the current page. The only downside is Previewing is only one page at a time – not whole site publishing.

  • You could also ask users to setup a specific publishing location for Emporter. Then when the users publishes to that location it would send Emporter the entire site.

  • Or maybe both?

  • It would be awesome to have a plugin that added buttons/hotkeys/etc that did that setup automatically – or just forced RW to do those things without literally setting them up at all.

A more automatic system might be hard. I don’t think there are any API hooks to connect to the publishing system. But I’ve never looked. I suspect you’d have to ask @tpbradley or @dan to add a few new hooks for your.

RW’s plugin system uses traditional Obj-C bundle loading.
If you’d like to go that route, you can start here: https://github.com/realmacsoftware/R…

I’m not sure of the state of that repo tho – and if it will build smoothly. I suspect it needs a bit of encouragement. :wink:

If it won’t build, feel free to ask me questions. I’m not from Realmac, but I know quite a bit about RW plugins. Probably more than most. :wink:

3 Likes

Hey Isaiah! Thanks for the retweet :slight_smile: Small world!

The goal I have in mind is to make it automatic with a minimal UI to show the current URL (and status). I looked over the API a few weeks ago and it seemed easy enough to derive the local site’s directory, but the server that ships with Emporter only serves static HTML.

Therefore, I think the best approach would be for me to use RW’s local preview server URL so I could serve sites which use PHP, which would possibly be auto-updated if needed. I’m not sure if the preview URL is accessible within the SDK, though… I’d have to poke around.

Thanks for offering your help! I’m cool with writing bundle-based plugins… I assumed that’s what I’d end up doing, but was slightly discouraged by the lack of documentation. I got in touch with RW support and was encouraged to join the dev forums. I’m glad I did!

1 Like

The good news is that the headers are very often easy to read and pretty extensive, covering a wide range of possible use cases.

The bad news is that there isn’t a lot of documentation. This means a lot of trial and error. But once you have things up and running the trial and error is pretty painless.

Welcome to the club. :smiley:

Welcome, Mike! @mikey

2 Likes