Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins #128

Open
fabiospampinato opened this issue Dec 29, 2018 · 5 comments
Labels
Milestone

Comments

@fabiospampinato
Copy link
Member

@fabiospampinato fabiospampinato commented Dec 29, 2018

Some people have expressed interest about adding a plugins architecture to the app.

This would require significant efforts to implement in a sufficiently mature and powerful way, but it would be very interesting to see.

@bendem

This comment has been minimized.

Copy link

@bendem bendem commented Jan 15, 2019

I'm interested in helping with this if I can (mainly, I want to help plugins get some traction so I can start implementing note encryption and cvs plugins). Do you already have some architecture ideas about what a plugin should look like, which things would be customisable and what plugins could do in general?

I can already see two kinds of plugins, the ones that will affect the UI, and the ones that will affect the notes.

UI plugin ideas:

  • Note formatting actions
  • Tag/note colours
  • Editor split view
  • markdown linting

Note plugin ideas:

  • cvs
  • gpg encryption

I have no idea what UI plugins would look like, but note plugins imo could be written as simple hooks:

  • read_note(metadata: NoteMetadata): Promise<string>
  • write_note(metadata: NoteMetadata, content: string): Promise
    there will be a need for good error handling so that those hooks can return a failed promise and have the error displayed to the user in a nice and actionable way.
@fabiospampinato

This comment has been minimized.

Copy link
Member Author

@fabiospampinato fabiospampinato commented Jan 15, 2019

@bendem For now I want to focus on other more pressing issues and on making the project long-term sustainable, I'll work on plugins after that.

Regarding the architecture there's nothing set in stone yet, but I think:

  • There should be APIs for contributing elements to the UI, mainly toolbar buttons, sidebar sections etc.
  • There should be hooks/events for some important things (reading/saving/rendering a note, searching etc.)
  • There should be some support for loading a custom CSS and JS file, as sometimes you just need to hide that element from the UI or make that small tweak, but all plugins shouldn't have to interact with the DOM directly, unless they are manipulating a full webview they are contributing.
  • Plugins should run on a separate process, so that a crash there doesn't take the whole app down.
  • There should be a website where people can download and publish plugins.
  • Some built-in features should be implemented as disable-able plugins.
@andyljones

This comment has been minimized.

Copy link

@andyljones andyljones commented Mar 22, 2019

I've a plugin candidate: a local server for importing research papers into Notable by clicking a bookmark. It currently needs to be installed and run as an independent process so yes, a plugin framework would be neat! It's no rush though, as it'll be too janky to package up for a long while yet.

@fabiospampinato

This comment has been minimized.

Copy link
Member Author

@fabiospampinato fabiospampinato commented Mar 22, 2019

@andyljones that's precisely the reason why we need plugins: not everything can be implemented into the core, but the app itself should be powerful enough to be able to support pretty much all use cases via plugins.

@Shagon94

This comment has been minimized.

Copy link

@Shagon94 Shagon94 commented Jul 9, 2019

@andyljones that's precisely the reason why we need plugins: not everything can be implemented into the core, but the app itself should be powerful enough to be able to support pretty much all use cases via plugins.

I agree, not everyone has a specific typing experience, some users might want versioning and encryption, some just want to jot their thoughts, plugins would open a great feature set that can be defined by the developers themselves, e.g. to implement themes, backup and sync to 3rd party services, application toast messages, automatic table of contents, a lot of extra functionality that can be build upon and into the project.

The main selling point for the plugins is that they are pluggable and not everyone has the need for them, however this relies on having a core that supports this such as the one build into vscode.

That being said plugins themselves could become obsolete if the functionality itself is build into the app or worked around it.

Versioning can be done via git, encryption with veracrypt or cryptomator, backup and sync with a simple dropbox, b2 backblaze or any other server.

The 1.6.0 version itself looks great and feels great using it. Not everyone has the need for every feature and thats fine since its up to the end user to decide if its worth their time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
4 participants
You can’t perform that action at this time.