Skip to content
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

remove application/javascript as this is not required with html5 #8710

Closed
sunnysideup opened this issue Jan 10, 2019 · 5 comments
Closed

remove application/javascript as this is not required with html5 #8710

sunnysideup opened this issue Jan 10, 2019 · 5 comments

Comments

@sunnysideup
Copy link
Contributor

sunnysideup commented Jan 10, 2019

Affected Version

SS4

Description

HTML5 does not require application/javascript
e.g.
https://github.com/silverstripe/silverstripe-framework/blob/4/src/View/Requirements_Backend.php#L807

I would go through all code and remove it.

This is helpful because when I run a w3 validation it throws a warning.

PRs

@lerni
Copy link
Contributor

lerni commented Jan 10, 2019

see also: #8221 (comment)

@robbieaverill
Copy link
Contributor

We support HTML4 as well as 5 at the moment so perhaps can't do this until we drop HTML4 support

@maxime-rainville
Copy link
Contributor

Would it be worthwhile making this configurable, so people who are coding to HTML5 can remove it and people who are coding to HTML4 still get it?

@chillu
Copy link
Member

chillu commented Jan 14, 2019

So @dhensby previously marked this as wontfix. HTML5 support in 5.x is tracked through #7310.

We should be able to determine if you're opted into HTML5 based on this config - but that part is quite separate from Requirements

SilverStripe\Core\Injector\Injector:
  SilverStripe\View\Parsers\HTMLValue:
    class: SilverStripe\View\Parsers\HTML4Value

I think we should just make this configurable in the requirements class as the path of least resistance. Do you want to send a PR for that @sunnysideup?

@GuySartorelli
Copy link
Member

PRs merged

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

No branches or pull requests

7 participants