Skip to content

Commit 1e202e1

Browse files
feat(package): added .gif loader
1 parent 9d9a414 commit 1e202e1

File tree

5 files changed

+5
-47
lines changed

5 files changed

+5
-47
lines changed

gatsby-config.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ module.exports = {
100100
rel: 'nofollow noopener noreferrer'
101101
}
102102
},
103-
104103
'gatsby-remark-responsive-iframe',
105104
'gatsby-remark-script',
106105
'gatsby-remark-autolink-headers',
@@ -118,7 +117,8 @@ module.exports = {
118117
// base for generating different widths of each image.
119118
maxWidth: 590
120119
}
121-
}
120+
},
121+
`gatsby-remark-copy-linked-files`
122122
]
123123
}
124124
},

gatsby-node.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
const path = require('path')
22
const _ = require('lodash')
33
const { writeFile } = require('fs')
4+
const md5 = require('blueimp-md5')
45

56
const searchData = []
67

@@ -42,7 +43,7 @@ exports.onCreateNode = ({ node, actions }) => {
4243
}
4344

4445
createNodeField({ node, name: 'slug', value: slug })
45-
46+
createNodeField({ node, name: 'identifier', value: md5(encodeURI(slug)) })
4647
searchData.push({ ...node.frontmatter, content: node.internal.content })
4748
}
4849
}

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
"gatsby-plugin-styled-components": "^3.0.1",
3333
"gatsby-plugin-typography": "^2.2.1",
3434
"gatsby-remark-autolink-headers": "^2.0.9",
35+
"gatsby-remark-copy-linked-files": "^2.6.0",
3536
"gatsby-remark-external-links": "0.0.4",
3637
"gatsby-remark-images": "^3.0.1",
3738
"gatsby-remark-prismjs": "^3.3.6",

src/lang/dist/en.dev.js

-22
This file was deleted.

src/lang/dist/zh.dev.js

-22
This file was deleted.

0 commit comments

Comments
 (0)