1
0
Fork 0

wip(new-design): Initial work to port to v3

This commit is contained in:
Joost De Cock 2022-10-06 14:15:13 +02:00
parent a94f1cc3ef
commit 9c488f6bcb
22 changed files with 999 additions and 444 deletions

View file

@ -0,0 +1,36 @@
import rdir from 'recursive-readdir'
import path from 'path'
const ignore = [
'package.json',
'node_modules',
'.eslint',
'.gitignore',
'.md',
'lab/components/header.js',
'lab/components/help-us.js',
'lab/components/search.js',
'lab/components/footer.js',
'shared/config/measurements.js',
]
const getFiles = async (dir) => {
const all = await rdir(path.resolve(dir))
return all
.filter((file) => {
for (const skip of ignore) {
if (file.includes(skip)) return false
}
return true
})
.map((file) => file.split('/sites/').pop())
}
const doIt = async () => {
let files = []
const shared = await getFiles('../../sites/shared')
const lab = await getFiles('../../sites/lab/components')
console.log(JSON.stringify([...shared, ...lab], null, 2))
}
doIt()