mirror of
https://github.com/seigler/awesome-dash-platform
synced 2025-07-27 06:36:08 +00:00
feat: clean up (a lot) (#247)
License: MIT Signed-off-by: Henrique Dias <hacdias@gmail.com>
This commit is contained in:
parent
6f15e77ed6
commit
a89015da98
12 changed files with 141 additions and 237 deletions
|
@ -3,18 +3,12 @@ const path = require('path')
|
|||
const files = require('./data')
|
||||
const readme = path.join(__dirname, '../README.md')
|
||||
const template = path.join(__dirname, 'readme-template.md')
|
||||
const { slugify, sortInv, sortAbc } = require('./utils')
|
||||
const { slugify } = require('./utils')
|
||||
|
||||
const toc = files.map(cat => `- [${cat.title}](#${slugify(cat.title)})`).join('\n')
|
||||
|
||||
const sections = files.map(category => {
|
||||
let sort = (a, b) => sortAbc(a.title, b.title)
|
||||
|
||||
if (category.title === 'Articles') {
|
||||
sort = (a, b) => sortInv(a.date, b.date)
|
||||
}
|
||||
|
||||
const content = category.content.sort(sort).map(item => {
|
||||
const content = category.content.map(item => {
|
||||
let block = '- '
|
||||
let mainUrl = ''
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue