mirror of https://github.com/xwiki-labs/cryptpad
removing `bower`: migrate `jquery`
Signed-off-by: Pamplemousse <git@xaviermaso.com>
This commit is contained in:
parent
86c7b42aae
commit
85d30328aa
|
@ -1,6 +1,7 @@
|
|||
datastore
|
||||
tasks
|
||||
www/bower_components/*
|
||||
www/components/*
|
||||
www/accounts
|
||||
node_modules
|
||||
/config.js
|
||||
|
|
|
@ -18,7 +18,6 @@
|
|||
"tests"
|
||||
],
|
||||
"dependencies": {
|
||||
"jquery": "3.6.0",
|
||||
"tweetnacl": "0.12.2",
|
||||
"components-font-awesome": "^4.6.3",
|
||||
"ckeditor": "4.14.0",
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -30,14 +30,16 @@
|
|||
"ws": "^3.3.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"jquery": "3.6.0",
|
||||
"jshint": "^2.13.4",
|
||||
"less": "3.7.1",
|
||||
"lesshint": "6.3.7",
|
||||
"selenium-webdriver": "^3.6.0"
|
||||
},
|
||||
"scripts": {
|
||||
"install:components": "node scripts/copy-components.js",
|
||||
"start": "node server.js",
|
||||
"dev": "DEV=1 node server.js",
|
||||
"dev": "npm run install:components && DEV=1 node server.js",
|
||||
"fresh": "FRESH=1 node server.js",
|
||||
"offline": "FRESH=1 OFFLINE=1 node server.js",
|
||||
"offlinedev": "DEV=1 OFFLINE=1 node server.js",
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
const Fs = require("fs");
|
||||
const Fse = require("fs-extra");
|
||||
const Path = require("path");
|
||||
|
||||
const componentsPath = Path.join("www", "components");
|
||||
Fse.mkdirpSync(componentsPath);
|
||||
|
||||
[
|
||||
"jquery",
|
||||
].forEach(l => {
|
||||
const source = Path.join("node_modules", l);
|
||||
const destination = Path.join(componentsPath, l);
|
||||
Fs.cpSync(source, destination, { recursive: true });
|
||||
});
|
|
@ -10,7 +10,7 @@ define([
|
|||
json: '/bower_components/requirejs-plugins/src/json',
|
||||
optional: '/lib/optional/optional',
|
||||
// jquery declares itself as literally "jquery" so it cannot be pulled by path :(
|
||||
"jquery": "/bower_components/jquery/dist/jquery.min",
|
||||
"jquery": "/components/jquery/dist/jquery.min",
|
||||
"mermaid": "/lib/mermaid/mermaid.min",
|
||||
// json.sortify same
|
||||
"json.sortify": "/bower_components/json.sortify/dist/JSON.sortify",
|
||||
|
|
|
@ -13,7 +13,7 @@ require.config({
|
|||
baseUrl: '/',
|
||||
paths: {
|
||||
// jquery declares itself as literally "jquery" so it cannot be pulled by path :(
|
||||
"jquery": "/bower_components/jquery/dist/jquery.min",
|
||||
"jquery": "/components/jquery/dist/jquery.min",
|
||||
// json.sortify same
|
||||
"json.sortify": "/bower_components/json.sortify/dist/JSON.sortify",
|
||||
cm: '/bower_components/codemirror'
|
||||
|
|
Loading…
Reference in New Issue