Closed koddsson closed 8 years ago
Hey! 👋 I need to organize things a bit in the project first so I can accept PRs. Webpages plugins are on the todo list though so that'll come soon – super happy learning about dotjs :)
Since the implementation might be a little different I'd suggest to maybe store the plugins in Application Support/Oryoki? Possibly also adding a menu toggle to turn everything on/off.
I need to organize things a bit in the project first so I can accept PRs.
Awesome! I'm in no rush to merge this since I can just use my current fork for now. If you need a hand you could label some issues and I might be able to pick some up when I have some spare time.
Since the implementation might be a little different I'd suggest to maybe store the plugins in Application Support/Oryoki?
I added a preference for plugin folder path in 6635d24 since I really like having my plugins at .js/
but it defaults to Application Support/Oryoki
:grinning:
Possibly also adding a menu toggle to turn everything on/off.
I didn't do this yet but I probably will soon.
Possibly also adding a menu toggle to turn everything on/off.
Ok I added this in a81bef4 but it's not persistant between reboots (just like show_title
) but there's a preference property now that you can set so that it starts with plugins either enabled or disabled (just like show_title
).
Just checked out your branch. Trying to wrap my head around it. Node paths are a little tricky I guess, so just using ~/Library/Application Support/Oryoki/plugins
doesn't work for me 😢
Q: why use ~/.js/
over Application Support? Easier to access from a terminal?
Hey there – branched off dev to implement the dotjs-like plugin system (5fc5edd). I think your PR came in a little early, but the project is ready-ish now. I'll branch off dev for every feature and merge back up to master for releases.
Basically your code, with a few tweaks: A – if the path defined in preferences isn't set we look for plugins in Application Support/Web Plugins. I need to rewrite a bit the preference file so it accepts comments to explain that. B – we reload the page when toggling the web plugins. I also added Tools > Browse Web Plugins...
.
I'm looking at adding a couple default plugins now. What are some useful ones? Thinking of one that adds a way of playing youtube etc. in full window, so you can have video players floating on top of everything else.
✌️
Hey! Web plugins are implemented in /dev as of 5645bc2 💥
Note: custom paths have to be absolute, so
~/.js
would be/Users/YourUserName/.js
Looks okay to me, but let me know if you end up using it and find anything :)
I included hot-reloading the preference file so you can change the directory without relaunching the app. The menu toggle also reloads the current view when turning the plugins on/off. Plugins can be activated independently on each window.
Hey! Web plugins are implemented in /dev as of 5645bc2 💥
✨✨✨ AWESOME ✨✨✨
Sorry for not being responsive about this PR but real life got in the way 😄
Hey hey 👋 I've no idea if you're accepting PRs to this project but I just saw it on HN and really like it.
Ever since the dotjs project got abandoned I've been looking for something similar. It works like dis:
Whenever a webpage is loaded we look for a file in
~/.js/<hostname>.js
and if we find one we read it's contents and execute the javascript we find there on the page we just loaded.I think the quote on the original dotjs project describes the functionality pretty well.