roam-unofficial / roam-toolkit

Roam force multiplier
MIT License
475 stars 43 forks source link

Run roam-toolkit over roam/js #164

Open Stvad opened 3 years ago

Stvad commented 3 years ago

133 has some initial investigations/thoughts

Stvad commented 3 years ago

You can run it now via the following roam/js snippet: (How to use roam/js)

var s = document.createElement('script')
  s.type = "text/javascript"
  // Version with all features enabled 
  // s.src =  "https://roam-toolkit.glitch.me/entry.js"
  // Version with Spatial Mode & Live preview disabled
  s.src =  "https://roam-toolkit.glitch.me/no_preview_spatial.js"
  s.async = true

document.getElementsByTagName('head')[0].appendChild(s)

Known issues:

cansar commented 3 years ago

Would it be possible to add settings to the roam/js version somehow? I absolutely love the Roam Toolkit SRS but am not a VIM user and would like to turn it off. I've been using the extension for a long time and would love to keep using it in Roam desktop (which lacks extension support).

Stvad commented 3 years ago

It's definitely possible, but I'm not sure If I'd have capacity to work on this soon :(

On Wed, Jun 2, 2021, 15:51 Can Sar @.***> wrote:

Would it be possible to add settings to the roam/js version somehow? I absolutely love the Roam Toolkit SRS but am not a VIM user and would like to turn it off. I've been using the extension for a long time and would love to keep using it in Roam desktop (which lacks extension support).

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/roam-unofficial/roam-toolkit/issues/164#issuecomment-853433126, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAT3Q4USZDIANS56XJIMSTTQ2YWNANCNFSM4SBK4CBA .

RobertKirk commented 2 years ago

You can run it now via the following roam/js snippet: (How to use roam/js)

var s = document.createElement('script')
  s.type = "text/javascript"
  // Version with all features enabled 
  // s.src =  "https://roam-toolkit.glitch.me/entry.js"
  // Version with Spatial Mode & Live preview disabled
  s.src =  "https://roam-toolkit.glitch.me/no_preview_spatial.js"
  s.async = true

document.getElementsByTagName('head')[0].appendChild(s)

Known issues:

  • no access to settings ui
  • It's likely there are a bunch of unknown issues :p

@Stvad, how did you build the code that's displayed there? I'm wanting to build my own version which I can host, so that I can then change the settings I want.

Stvad commented 2 years ago

@RobertKirk See roam-js branch. It removes the dependencies incompatible with running in roam-js, then do normal build as described in contribution guide and use the resulting content script

RobertKirk commented 2 years ago

@Stvad thanks a lot!

mharmel commented 1 year ago

@RobertKirk Did you end up building a version without VIM mode activated? If so, would you share the .js script?

RobertKirk commented 1 year ago

I wanted vim mode activated, but I haven't gotten around to it, sorry.