Skip to content
This repository has been archived by the owner on Nov 20, 2024. It is now read-only.

Better explain subtheme inheritance in STARTERKIT #87

Open
tobybellwood opened this issue Feb 21, 2018 · 1 comment
Open

Better explain subtheme inheritance in STARTERKIT #87

tobybellwood opened this issue Feb 21, 2018 · 1 comment

Comments

@tobybellwood
Copy link

We probably don't explain the inheritance of STARTERKIT/js/script.js properly in STARTERKIT/README-FIRST.txt

From https://www.drupal.org/docs/7/theming/creating-a-sub-theme:

JavaScript inheritance
All JavaScript files defined in the parent theme will be inherited.

Overriding inherited JavaScript: Specify a JavaScript file with the same filename in the sub-theme's .info file. For instance, to override script.js inherited from a parent theme, add the following line to your sub-theme's .info file:

scripts[] = script.js

You will also need to create the script.js file; if you simply wish to disable the imported scripts, you can create an empty file.

@rujiali
Copy link
Contributor

rujiali commented Feb 21, 2018

In fact, there are multiple ways to add JS. We don't have to add this empty example here. I propose we remove the JS folder, devs can add JS the way they like.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants