Skip to content

Commit

Permalink
Make compatible with Dekode Starter Theme
Browse files Browse the repository at this point in the history
  • Loading branch information
pdewouters committed Aug 23, 2023
1 parent f88b5c5 commit 819171c
Show file tree
Hide file tree
Showing 247 changed files with 10,244 additions and 5,192 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ dist
build
vendor
wp
packages/themes/dekode-starter-theme/src/register-block-extension
3 changes: 3 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,7 @@ module.exports = {
},
requireConfigFile: false,
},
settings: {
'import/core-modules': ['@t2/editor'],
},
};
10 changes: 10 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,13 @@ sql/
# Other
debug.log
wp-debug.log
public/apple-touch-icon.png
public/android-chrome-192x192.png
public/android-chrome-512x512.png
public/browserconfig.xml
public/favicon-16x16.png
public/favicon-32x32.png
public/favicon.ico
public/mstile-150x150.png
public/safari-pinned-tab.svg
public/site.webmanifest
2 changes: 1 addition & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dist
build
vendor
wp
*.css
# *.css
*.lock
*.md
package-lock.json
25 changes: 19 additions & 6 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
module.exports = {
useTabs: true,
tabWidth: 4,
singleQuote: true,
trailingComma: 'all',
};
// Import the default config file and expose it in the project root.
// Useful for editor integrations.
module.exports = require('@wordpress/prettier-config');
module.exports.overrides = [
{
files: ['*.css'],
options: {
printWidth: 1000,
singleQuote: false,
},
},
{
files: ['*.js'],
options: {
printWidth: 80,
trailingComma: 'es5',
},
},
];
13 changes: 2 additions & 11 deletions .stylelintrc.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
extends: ['@wordpress/stylelint-config/scss'],
extends: ['@wordpress/stylelint-config'],
rules: {
'at-rule-empty-line-before': null,
'at-rule-no-unknown': null,
Expand All @@ -10,16 +10,7 @@ module.exports = {
'rule-empty-line-before': null,
'selector-class-pattern': null,
'value-keyword-case': null,
'scss/operator-no-unspaced': null,
'scss/selector-no-redundant-nesting-selector': null,
'scss/at-import-partial-extension': null,
'scss/no-global-function-names': null,
'scss/comment-no-empty': null,
'scss/at-extend-no-missing-placeholder': null,
'scss/operator-no-newline-after': null,
'scss/at-if-closing-brace-newline-after': null,
'scss/at-else-empty-line-before': null,
'scss/at-if-closing-brace-space-after': null,
'no-invalid-position-at-import-rule': null,
'function-url-quotes': null,
},
};
12 changes: 11 additions & 1 deletion INSTALLATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Themes, plugins, mu-plugins etc. is now structured under packages and built into

### wp-cli and Local by Flywheel

To be able to use wp-cli, you can use [Local by Flywheel](https://localwp.com/) build-in in site shell.
To be able to use wp-cli, you can use [Local by Flywheel](https://localwp.com/) build-in in site shell.

If you would like to access the wp-cli in the defauly system console there can be issues trying to use wp-cli commands when using a [Local by Flywheel](https://localwp.com/) development environment. You can usually fix this with the following steps:

Expand Down Expand Up @@ -130,6 +130,16 @@ Project-base uses wp-scripts to build front end assets using the `npm run build`

6. Install the package using `composer update` or `npm install` depending on type. you might need to re-run `npm run build` or `npm run start` if you have installed a new package containing files that need building.

### Renaming

There are several places where literal strings need to be renamed to match the project:

- app/postcss.config.js:19
- app/package.json:80 (Set these values according to design)
- app/composer.json:9 (Update dependency name)
- app/tools/webpack/blocks.js:24 (path to block library)
- Any other namespace / text domain / theme - plugin headers

## Documentation
* PostCSS [https://github.com/postcss/postcss/tree/main/docs](https://github.com/postcss/postcss/tree/main/docs)
* WebPack [https://webpack.js.org/concepts/](https://webpack.js.org/concepts/)
Expand Down
7 changes: 4 additions & 3 deletions anonymize.config.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"patterns": [
{
"tableName": ".*_users",
"tableName": "wp_users",
"fields": [
{
"field": "user_login",
Expand Down Expand Up @@ -42,7 +42,7 @@
]
},
{
"tableName": ".*_usermeta",
"tableName": "wp_usermeta",
"fields": [
{
"field": "meta_value",
Expand Down Expand Up @@ -95,7 +95,8 @@
]
},
{
"tableName": ".*_comments",
"tableName": "wp_comments",
"tableNameRegex": ".*_comments",
"fields": [
{
"field": "comment_author",
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"php": ">=8.1",
"boxuk/wp-muplugin-loader": "~2.0.0",
"composer/installers": "~2.2.0",
"dekode/dekode-theme": "~1.0.0",
"dekode/dekode-starter-theme": "^0.7.0",
"dekode/imagify-helper": "1.0.0",
"dekodeinteraktiv/dekode-label-environment": "~1.0.0",
"inpsyde/wp-translation-downloader": "~2.4.0",
Expand Down
Loading

0 comments on commit 819171c

Please sign in to comment.