mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-05 13:02:54 +00:00
feat: migrate to esm
This commit is contained in:
2
examples/minimal-plugin/app.js
Normal file
2
examples/minimal-plugin/app.js
Normal file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env node
|
||||
import './lib/cli.js'
|
||||
@@ -2,6 +2,7 @@
|
||||
"name": "@openstapps/minimal-plugin",
|
||||
"description": "Minimal Plugin",
|
||||
"version": "2.1.0",
|
||||
"type": "module",
|
||||
"license": "GPL-3.0-only",
|
||||
"author": "Thea Schöbl",
|
||||
"contributors": [
|
||||
@@ -36,7 +37,7 @@
|
||||
"@types/node": "18.15.3",
|
||||
"conventional-changelog-cli": "2.2.2",
|
||||
"rimraf": "4.4.0",
|
||||
"typedoc": "0.22.18",
|
||||
"typescript": "4.4.4"
|
||||
"typedoc": "0.23.26",
|
||||
"typescript": "4.8.4"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
#!/usr/bin/env node
|
||||
|
||||
/*
|
||||
* Copyright (C) 2019-2021 StApps
|
||||
* This program is free software: you can redistribute it and/or modify it
|
||||
@@ -15,14 +13,14 @@
|
||||
* this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import {HttpClient} from '@openstapps/api/lib/http-client';
|
||||
import {PluginClient} from '@openstapps/api/lib/plugin-client';
|
||||
import {Converter} from '@openstapps/core-tools/lib/schema';
|
||||
import {HttpClient} from '@openstapps/api/lib/http-client.js';
|
||||
import {PluginClient} from '@openstapps/api/lib/plugin-client.js';
|
||||
import {Converter} from '@openstapps/core-tools/lib/schema.js';
|
||||
import {Logger} from '@openstapps/logger';
|
||||
import {Command, Option} from 'commander';
|
||||
import {readFileSync} from 'fs';
|
||||
import {join, resolve} from 'path';
|
||||
import {MinimalPlugin} from './plugin/minimal-plugin';
|
||||
import {MinimalPlugin} from './plugin/minimal-plugin.js';
|
||||
|
||||
|
||||
process.on('unhandledRejection', (error) => {
|
||||
|
||||
@@ -12,10 +12,10 @@
|
||||
* You should have received a copy of the GNU General Public License along with
|
||||
* this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
import {Plugin} from '@openstapps/api/lib/plugin';
|
||||
import {Plugin} from '@openstapps/api/lib/plugin.js';
|
||||
import * as express from 'express';
|
||||
import {SCMinimalRequest} from './protocol/request';
|
||||
import {SCMinimalResponse} from './protocol/response';
|
||||
import {SCMinimalRequest} from './protocol/request.js';
|
||||
import {SCMinimalResponse} from './protocol/response.js';
|
||||
|
||||
/**
|
||||
* The Plugin Class
|
||||
|
||||
Reference in New Issue
Block a user