我按照他的解释-https://github.com/GrahamCampbell/Laravel-Markdown/blob/master/README.md
var knex = require("knex")({
client: "sqlite3",
connection: {
filename: "./SettingsDB.sqlite"
},
useNullAsDefault: true
});
const bookshelf = require("bookshelf")(knex);
const PAProbes = bookshelf.Model.extend({
tableName: "PAProbes"
});
const ConventionalProbes = bookshelf.Model.extend({
tableName: "ConventionalProbes"
});
// PAProbes.fetchAll().then(function(resData) {
// return resData.toJSON();
// });
var test = ConventionalProbes.fetchAll()
.then(resData => {
return resData.toJSON();
})
.catch(error => {
console.log(error);
})
.finally(() => {
knex.destroy();
});
console.log(JSON.stringify(test));
$ composer require graham-campbell/markdown
注册
作为别名,将此GrahamCampbell\Markdown\MarkdownServiceProvider::class,
添加到'Markdown' => GrahamCampbell\Markdown\Facades\Markdown::class,
文件中。config/app.php
当它不起作用时,然后我运行配置-{!! Markdown::convertToHtml($post->content) !!}
然后再试一次。不幸的是,它仍然无法正常工作。
有什么我想念的吗?请帮助我进行正确的安装。