-
-
Notifications
You must be signed in to change notification settings - Fork 8.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(v2): convert @docusaurus/plugin-ideal-image
to TypeScript
#2011
refactor(v2): convert @docusaurus/plugin-ideal-image
to TypeScript
#2011
Conversation
refactor @docusaurus/plugin-ideal-image
Deploy preview for docusaurus-2 ready! Built with commit 882bad9 |
Deploy preview for docusaurus-preview ready! Built with commit 882bad9 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually this broke the plugin itself :(
https://deploy-preview-2011--docusaurus-2.netlify.com/showcase/
It's a permanent low quality placeholder now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much @gimdongwoo! Please have a look at the comments
@@ -0,0 +1,21 @@ | |||
declare module '@endiliey/react-ideal-image' { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to add the copyright header
/**
* Copyright (c) 2017-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
@@ -4,10 +4,13 @@ | |||
* This source code is licensed under the MIT license found in the | |||
* LICENSE file in the root directory of this source tree. | |||
*/ | |||
import {LoadContext} from '@docusaurus/types'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leave an empty line after the copyright header.
|
||
module.exports = function(context, options) { | ||
export = function(_context: LoadContext, options: PluginOptions) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be export default
@yangshun I’m really sorry. I am too busy recent 2 weeks. |
No problem, thanks for starting this, the fixes required were really minor. Thank you!!! 🎉 |
It works when I build locally but not on Netlify. Super weird. I thought it
could be a caching issue so I uploaded my local files to Netlify lol.
…On Sun, Dec 1, 2019, 5:52 AM Endi ***@***.***> wrote:
OOps this PR broke something
[image: image]
<https://user-images.githubusercontent.com/17883920/69914978-89493d00-147c-11ea-9c6b-87c545ac6dd3.png>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2011?email_source=notifications&email_token=AAKBCHOWSYFSIUO3QUR4BLDQWO6TNA5CNFSM4JOKHXU2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFRJ2VY#issuecomment-560110935>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAKBCHNO42QKRMLAJWWYYV3QWO6TNANCNFSM4JOKHXUQ>
.
|
refactor @docusaurus/plugin-ideal-image
Motivation
I want to refactor every plugin to typescript. It helps consistency and maintainability.
Have you read the Contributing Guidelines on pull requests?
Yes
Test Plan
Compiling and testing are passed.
Related PRs
#1997