Although this isn't a problem in other languages, because of semicolon insertion, there could be problems if you don't place the bracket on the opening line:
// no:
function()
{| const puppeteer = require('puppeteer') | |
| let anime = {} | |
| async function run (searched) { | |
| searched = searched.replace(';', ' ') | |
| // Setup pupeteer | |
| const browser = await puppeteer.launch({ | |
| headless: false, | |
| }) |
| Array.from(document.querySelectorAll('h4')).map((el) => { | |
| const nextEl = el.nextElementSibling | |
| const tableEl = nextEl.nextElementSibling | |
| return ` | |
| /**${nextEl.innerText.replace(/(.{1,72}\s)\s*?/g, '\n * $1')} | |
| */ | |
| export type ${el.innerText} = { | |
| ` + Array.from(tableEl.children[0].children).slice(1).map((tr) => { | |
| const arr = Array.from(tr.children) |
| import { fetchChatList } from 'api/chatList'; | |
| import { api } from 'helpers/Telegram/pool'; | |
| import * as React from 'react'; | |
| import { Context, Params, Route } from 'universal-router'; | |
| import history from '../../history'; | |
| export const resolveRoute = async (context: Context, params: Params) => { | |
| const { route, store } = context; | |
| const { auth } = store.getState(); |
| 'use scrict' | |
| class Middleware { | |
| // optional | |
| constructor () { | |
| } | |
| // required |
| this.options = typeof options === 'function' | |
| ? { steps: [options, ...steps], leaveHandlers: [] } | |
| : Object.assign({ steps: steps, leaveHandlers: [] }, options) | |
| this.options = typeof options === 'function' | |
| ? { steps: [options, ...steps], leaveHandlers: [] } | |
| : { ...{ steps: steps, leaveHandlers: [] }, ...options } |
| import extend from 'extend' | |
| /** | |
| * Class Validator. | |
| * | |
| * @class Validator | |
| */ | |
| export default class Validator { | |
| /** |
| <?php namespace Anomaly\Streams\Platform\Model; | |
| use Anomaly\Streams\Platform\Support\Presenter; | |
| use Illuminate\Contracts\Support\Arrayable; | |
| /** | |
| * Class EloquentPresenter | |
| * The base presenter for all our models. | |
| * | |
| * @link http://pyrocms.com/ |
| <?php namespace Defr\FtlTheme\Page\Command; | |
| use Anomaly\FilesModule\Disk\Contract\DiskRepositoryInterface; | |
| use Anomaly\FilesModule\Folder\Contract\FolderRepositoryInterface; | |
| use Anomaly\PagesModule\Page\Contract\PageInterface; | |
| use Anomaly\Streams\Platform\Model\Pages\PagesEventPagesEntryModel; | |
| class CreateFolder | |
| { |