ant-design/scripts/build-website.js

21 lines
596 B
JavaScript
Raw Normal View History

2016-02-29 14:27:11 +08:00
#! /usr/bin/env node
'use strict';
2016-03-01 10:41:09 +08:00
// Ensure that data directory exist.
2016-03-22 11:32:49 +08:00
require('mkdirp').sync('./_data');
2016-03-01 10:41:09 +08:00
2016-02-29 14:27:11 +08:00
const buildDemosList = require('./build-demos-list');
2016-03-22 11:32:49 +08:00
buildDemosList(['./components', './docs'], './_data/demos-list.js');
2016-02-29 14:27:11 +08:00
2016-03-08 15:35:03 +08:00
const buildCommon = require('./build-common');
2016-03-04 18:06:34 +08:00
buildCommon([
'./components',
'./docs/react',
'./CHANGELOG.md',
2016-03-22 11:32:49 +08:00
], './_data/react-components.js');
buildCommon('./docs/practice', './_data/practice.js');
buildCommon('./docs/pattern', './_data/pattern.js');
buildCommon('./docs/spec', './_data/spec.js');
buildCommon('./docs/resource', './_data/resource.js');