![文件引入(import require)](https://img2020.cnblogs.com/blog/2029843/202110/2029843-20211014154948757-281209889.png)
文件引入(import require)
文件引入(import require)
规范
-
require 是AMD规范引入方式
-
import 是es6的一个语法标准
调用时间
-
require 是运行时调用
-
import 是编译时调用
require 的用法
- const fs = require('fs')
- exports.fs = fs
- module.exports = fs
import 的用法
-
import fs from 'fs'
-
import {default as fs} from 'fs'
-
import * as fs from 'fs'
-
import {readFile} from 'fs'
-
import {readFile as read} from 'fs'
-
import fs, {readFile} from 'fs'
-
export default fs
-
export const fs
-
export function readFile
-
export
-
export * from 'fs'
posted @
2021-10-14 15:45
boyyang
阅读(
608)
评论()
编辑
收藏
举报
//黑猫咪:https://unpkg.com/live2d-widget-model-hijiki@1.0.5/assets/hijiki.model.json
//白猫咪:https://unpkg.com/live2d-widget-model-tororo@1.0.5/assets/tororo.model.json
//萌娘:https://unpkg.com/live2d-widget-model-shizuku@1.0.5/assets/shizuku.model.json
//狗狗:https://unpkg.com/live2d-widget-model-wanko@1.0.5/assets/wanko.model.json
//萌妹1号:https://unpkg.com/live2d-widget-model-z16@1.0.5/assets/z16.model.json
//萌妹2号:https://unpkg.com/live2d-widget-model-koharu@1.0.5/assets/koharu.model.json
//萌妹3号:https://unpkg.com/live2d-widget-model-hibiki@1.0.5/assets/hibiki.model.json
//妹子4号:https://unpkg.com/live2d-widget-model-izumi@1.0.5/assets/izumi.model.json
//妹子5号:https://unpkg.com/live2d-widget-model-miku@1.0.5/assets/miku.model.json
//6号:https://unpkg.com/live2d-widget-model-nico@1.0.5/assets/nico.model.json
//7号:https://unpkg.com/live2d-widget-model-ni-j@1.0.5/assets/ni-j.model.json
//8号:https://unpkg.com/live2d-widget-model-nipsilon@1.0.5/assets/nipsilon.model.json
//9号:https://unpkg.com/live2d-widget-model-nito@1.0.5/assets/nito.model.json
//10号:https://unpkg.com/live2d-widget-model-tsumiki@1.0.5/assets/tsumiki.model.json
//11号:https://unpkg.com/live2d-widget-model-unitychan@1.0.5/assets/unitychan.model.json
//帅哥1号:https://unpkg.com/live2d-widget-model-chitose@1.0.5/assets/chitose.model.json
//帅哥2号:https://unpkg.com/live2d-widget-model-haruto@1.0.5/assets/haruto.model.json