Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
node_modules/
build/
.prettierrc
.eslintrc
env.d.ts
41 changes: 26 additions & 15 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,18 +1,29 @@
{
"env": {
"browser": true,
"es6" : true,
"node": true
},
"extends": [
"eslint:recommended"
],
"parserOptions": {
"ecmaVersion": 12,
"sourceType": "module"
},
"rules": {
"no-unused-vars": 0,
"no-undef": 2
"parserOptions": {
"ecmaVersion": 2021,
"sourceType": "module"
},
"extends": [
"plugin:import/recommended",
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
// This disables the formatting rules in ESLint that Prettier is going to be responsible for handling.
// Make sure it's always the last config, so it gets the chance to override other configs.
"eslint-config-prettier"
],
"settings": {
"import/resolver": {
"node": {
"extensions": [".js", ".jsx", ".ts", ".tsx"],
"moduleDirectory": ["node_modules", "src/"]
}
}
},
"rules": {
"no-unused-vars": "off"
},
"env": {
"browser": true,
"node": true
}
}
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v16.14.2
v17.7.1
6 changes: 6 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.prettierrc

dist/
node_modules/
vendor/
**/*.php
18 changes: 18 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"arrowParens": "always",
"bracketSpacing": true,
"embeddedLanguageFormatting": "auto",
"endOfLine": "lf",
"htmlWhitespaceSensitivity": "css",
"insertPragma": false,
"order": "alphabetical",
"printWidth": 120,
"proseWrap": "preserve",
"quoteProps": "as-needed",
"requirePragma": false,
"semi": true,
"singleQuote": true,
"tabWidth": 2,
"trailingComma": "all",
"useTabs": false
}
184 changes: 0 additions & 184 deletions .sass-lint.yml

This file was deleted.

9 changes: 9 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"extends": ["stylelint-config-standard", "stylelint-config-prettier"],
"ignoreFiles": ["./build/**/*.css"],
"rules": {
"alpha-value-notation": "number",
"at-rule-no-unknown": null,
"color-function-notation": "legacy"
}
}
40 changes: 19 additions & 21 deletions 404.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,26 @@

get_header(); ?>

<div class="uk-container uk-container-large">
<div uk-grid>
<div id="primary" class="uk-width-s">
<header class="entry__header">
<h1 class="hdg hdg--1">
<?php _e('Page Not Found', 'mc-starter'); ?>
</h1>
</header><!-- /.entry__header -->
<div class="container flex space-x-2 mx-auto">
<main id="primary" class="w-full md:w-3/4">
<header class="entry__header">
<h1 class="hdg hdg--1">
<?php _e('Page Not Found', 'mc-starter'); ?>
</h1>
</header><!-- /.entry__header -->

<div class="entry__content">
<?php
_e(
'<p>It seems we can&rsquo;t find what you&rsquo;re looking for. Perhaps searching can help.</p>',
'mc-starter'
);
get_search_form();
?>
</div><!-- /.entry__content -->
</div><!-- /#primary -->
<div class="entry__content">
<?php
_e(
'<p>It seems we can&rsquo;t find what you&rsquo;re looking for. Perhaps searching can help.</p>',
'mc-starter'
);
get_search_form();
?>
</div><!-- /.entry__content -->
</main><!-- /#primary -->

<?php get_sidebar(); ?>
</div>
<?php get_sidebar(); ?>
</div>

<?php get_footer();
<?php get_footer();
3 changes: 1 addition & 2 deletions App/Menus/PrimaryMenuWalker.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
*/
class PrimaryMenuWalker extends Walker_Nav_Menu
{

public function __construct()
{
add_filter('nav_menu_css_class', [$this, 'navMenuCssClasses'], 10, 3);
Expand Down Expand Up @@ -96,7 +95,7 @@ public function navMenuItemTitle($title, $item, $args, $depth)
if ('primary' !== $args->theme_location) {
return $title;
}

if ($args->walker->has_children && $depth === 0) {
$title .= ' <span class="caret"></span>';
}
Expand Down
10 changes: 2 additions & 8 deletions App/Scripts.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,9 @@ public function addHooks()
*/
public function enqueueScripts()
{
// set the unminified file type if we're in development env.
$filename = '.min';
if (isset($_ENV['WP_ENV']) && 'development' === $_ENV['WP_ENV']) {
$filename = '';
}

wp_enqueue_script(
'mc-theme',
get_template_directory_uri() . "/build/js/theme{$filename}.js",
get_template_directory_uri() . "/build/scripts/theme-scripts.min.js",
[],
THEME_VERSION,
true
Expand All @@ -52,7 +46,7 @@ public function enqueueStyles()
{
wp_enqueue_style(
'mc-styles',
get_template_directory_uri() . '/build/css/theme.min.css',
get_template_directory_uri() . '/build/styles/theme-styles.min.css',
[],
THEME_VERSION
);
Expand Down
Loading