mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Treating API urls as external in cells
Summary: Links for the API endpoints in a cell didn't work as they were interpreted as internal routes. Now they are properly detected as external. Test Plan: Added new test Reviewers: paulfitz Reviewed By: paulfitz Differential Revision: https://phab.getgrist.com/D4078
This commit is contained in:
@@ -188,6 +188,9 @@ export class UrlStateImpl {
|
||||
* a matter of DocWorker requiring a different version (e.g. /v/OTHER/doc/...).
|
||||
*/
|
||||
public needPageLoad(prevState: IGristUrlState, newState: IGristUrlState): boolean {
|
||||
// If we have an API URL we can't use it to switch the state, so we need a page load.
|
||||
if (newState.api || prevState.api) { return true; }
|
||||
|
||||
const gristConfig = this._window.gristConfig || {};
|
||||
const orgReload = prevState.org !== newState.org;
|
||||
// Reload when moving to/from a document or between doc and non-doc.
|
||||
|
||||
Reference in New Issue
Block a user