josephg / ShareJS

Collaborative editing in any app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Changing the general basepath of ShareJS

luto opened this issue · comments

commented

Currently it's not possible the change the basepath of ShareJS because rest.js always handles /doc/:foo, as seen here in line 74. I'd suggest adding an base-setting just like the one browserChannel already has:

var options =
  {
    browserChannel:
    {
      base: "/sharejs/sock_bc"
    },
    rest:
    {
      base: "/sharejs/rest"
    }
  }
sharejs.attach(app, options);
// ... etc