Skip to content

Instantly share code, notes, and snippets.

View hypeJunction's full-sized avatar

Ismayil Khayredinov hypeJunction

View GitHub Profile
export default class App {
constructor (services) {
this.services = services;
}
start () {
const { express, db } = this.services;
if (!db.models) {
db.loadModels(this.services);
const vuedoc = require('@vuedoc/parser');
const config = require('../../src/noah.config');
const fs = require('fs');
const path = require('path');
const jobs = Object.keys(config.components).map((name) => {
const component = config.components[name];
const componentPath = component.path ? path.resolve(__dirname, '../../src/', component.path) : '../../src/elements';
return vuedoc.parse({ filename: path.resolve(__dirname, `${componentPath}/${name}.vue`) });
[{
"name": "Button",
"description": null,
"keywords": [],
"slots": [
{
"kind": "slot",
"visibility": "public",
"description": "",
"keywords": [],
<template>
<div class="component-meta">
<n-box v-if="meta.description">{{ meta.description }}</n-box>
<n-module type="demo" class="component-meta">
<div slot="header"></div>
<n-tabs :items="tabs">
<component-props slot="props" :data="meta.props"></component-props>
<component-slots slot="slots" :data="meta.slots"></component-slots>
<component-events slot="events" :data="meta.events"></component-events>
<template>
<n-module type="demo">
<div slot="header" class="demo">
<component :is="`demos-${name}`"/>
</div>
<div class="code">
<codemirror :value="raw" :options="cmOptions"></codemirror>
</div>
</n-module>
export default (
{
Vue, // the version of Vue being used in the VuePress app
options, // the options for the root Vue instance
router, // the router instance for the app
siteData, // site metadata
},
) => {
Vue.component('codemirror', async () => {
// This module will export a function configuring codemirror component
import codemirror from 'vue-codemirror/src/codemirror.vue';
export default (config) => {
if (config) {
if (config.options) {
codemirror.props.globalOptions.default = () => config.options;
}
if (config.events) {
codemirror.props.globalEvents.default = () => config.events;
}
{
"private": true,
"scripts": {
"dev": "nodemon --watch mod -e php,js,css --exec \"php -f ./scripts/reset.php && php -f ./scripts/cache.php\""
}
}
<?php
require_once dirname(dirname(__FILE__)) . "/vendor/autoload.php";
\Elgg\Application::start();
_elgg_services()->simpleCache->invalidate();
_elgg_services()->systemCache->reset();
error_log('Cache has been flushed');
<?php
require_once dirname(dirname(__FILE__)) . "/vendor/autoload.php";
\Elgg\Application::start();
$view_list = _elgg_services()->views->listViews();
$get_processed_view = function($view, $viewtype) {
elgg_set_viewtype($viewtype);