That’s how i did it at the moment:
import {ajax} from "discourse/lib/ajax";
...
let post = this.findAncestorModel();
ajax(`/posts/${post.id}`, { type: "GET", cache: false }).then(
(result) => {
console.log(result.raw);
}
);
That’s how i did it at the moment:
import {ajax} from "discourse/lib/ajax";
...
let post = this.findAncestorModel();
ajax(`/posts/${post.id}`, { type: "GET", cache: false }).then(
(result) => {
console.log(result.raw);
}
);