[READ-ONLY] Mirror of https://github.com/danielroe/siroc. Zero-config build tooling for Node
bundle node package rollup typescript
0

Configure Feed

Select the types of activity you want to include in your feed.

style: simplify walkDownDirectory util

Daniel Roe (Mar 14, 2021, 10:42 AM UTC) 2df52f7e db6102bf

+2 -4
+2 -4
src/core/package/utils.ts
··· 1 1 import { sep } from 'upath' 2 2 import type { PackageJson } from './types' 3 3 4 - const walkDownDirectory = (pathname: string) => { 5 - const [first, ...rest] = pathname.split(sep) 6 - return rest.join(sep) 7 - } 4 + const walkDownDirectory = (pathname: string) => 5 + pathname.split(sep).slice(1).join(sep) 8 6 9 7 export const getEntrypointPaths = (path: string) => { 10 8 if (path.startsWith('./')) path = path.slice(2)