Skip to content

Commit

Permalink
refactor: var to const
Browse files Browse the repository at this point in the history
  • Loading branch information
yoshinorin committed Feb 28, 2023
1 parent a38e48b commit 1958fb2
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/plugins/helper/date.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,4 +92,4 @@ export {fullDateHelper as full_date};
export {relativeDateHelper as relative_date};
export {timeTagHelper as time_tag};
export {moment};
export var toMomentLocale = moize.shallow(_toMomentLocale);
export const toMomentLocale = moize.shallow(_toMomentLocale);
2 changes: 1 addition & 1 deletion lib/theme/processors/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ export function process(file) {
});
}

export var pattern = new Pattern(/^_config\.\w+$/);
export const pattern = new Pattern(/^_config\.\w+$/);
2 changes: 1 addition & 1 deletion lib/theme/processors/i18n.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ export function process(file) {
});
}

export var pattern = new Pattern('languages/*path');
export const pattern = new Pattern('languages/*path');
2 changes: 1 addition & 1 deletion lib/theme/processors/source.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export function process(file) {
});
}

export var pattern = new Pattern(path => {
export const pattern = new Pattern(path => {
if (!path.startsWith('source/')) return false;

path = path.substring(7);
Expand Down
4 changes: 2 additions & 2 deletions lib/theme/processors/view.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Pattern} from 'hexo-util';
import { Pattern } from 'hexo-util';

export function process(file) {
const { path } = file.params;
Expand All @@ -13,4 +13,4 @@ export function process(file) {
});
}

export var pattern = new Pattern('layout/*path');
export const pattern = new Pattern('layout/*path');

0 comments on commit 1958fb2

Please sign in to comment.