Skip to content
Snippets Groups Projects
Commit dd5e46ab authored by Fatih Acet's avatar Fatih Acet
Browse files

Merge branch 'eslint' into 'master'

Add ESLint

## What does this MR do?

- create `package.json`
- add ESLint dependencies to `package.json`
- add JavaScript linting to CI
- add Rake task `lint:javascript`as alias for `eslint` (which itself is an alias for `npm run eslint`)

## Are there points in the code the reviewer needs to double check?

Probably not.

## Why was this MR needed?

My hovercraft was full of eels.

## What are the relevant issue numbers?

- https://gitlab.com/gitlab-org/gitlab-ce/issues/13224#note_12537431
- https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5006#note_13255658


See merge request !5445
parents 5a4dabd0 02f94cf0
No related branches found
No related tags found
No related merge requests found
Showing
with 52 additions and 0 deletions
/public/
/tmp/
/vendor/
{
"extends": "airbnb",
"globals": {
"$": false,
"_": false,
"beforeEach": false,
"d3": false,
"define": false,
"describe": false,
"document": false,
"expect": false,
"fixture": false,
"gl": false,
"it": false,
"jQuery": false,
"Mousetrap": false,
"spyOn": false,
"spyOnEvent": false,
"Turbolinks": false,
"window": false
}
}
Loading
Loading
@@ -37,6 +37,7 @@
/doc/code/*
/dump.rdb
/log/*.log*
/node_modules/
/nohup.out
/public/assets/
/public/uploads.*
Loading
Loading
Loading
Loading
@@ -311,6 +311,14 @@ coverage:
- coverage/index.html
- coverage/assets/
 
lint-javascript:
stage: test
image: "node:latest"
before_script:
- npm install
script:
- npm run eslint
# Trigger docs build
# https://gitlab.com/gitlab-com/doc-gitlab-com/blob/master/README.md#deployment-process
trigger_docs:
Loading
Loading
/* eslint-disable */
((global) => {
const MAX_MESSAGE_LENGTH = 500;
const MESSAGE_CELL_SELECTOR = '.abuse-reports .message';
Loading
Loading
/* eslint-disable */
(function() {
this.Activities = (function() {
function Activities() {
Loading
Loading
/* eslint-disable */
(function() {
this.Admin = (function() {
function Admin() {
Loading
Loading
/* eslint-disable */
(function() {
this.Api = {
groupsPath: "/api/:version/groups.json",
Loading
Loading
/* eslint-disable */
// This is a manifest file that'll be compiled into including all the files listed below.
// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
// be included in the compiled file accessible from http://example.com/assets/application.js
Loading
Loading
/* eslint-disable */
(function() {
this.Aside = (function() {
function Aside() {
Loading
Loading
/* eslint-disable */
(function() {
this.Autosave = (function() {
function Autosave(field, key) {
Loading
Loading
/* eslint-disable */
(function() {
this.AwardsHandler = (function() {
const FROM_SENTENCE_REGEX = /(?:, and | and |, )/; //For separating lists produced by ruby's Array#toSentence
Loading
Loading
/* eslint-disable */
 
/*= require jquery.ba-resize */
/*= require autosize */
Loading
Loading
/* eslint-disable */
(function() {
$(function() {
$("body").on("click", ".js-details-target", function() {
Loading
Loading
/* eslint-disable */
// Quick Submit behavior
//
// When a child field of a form with a `js-quick-submit` class receives a
Loading
Loading
/* eslint-disable */
// Requires Input behavior
//
// When called on a form with input fields with the `required` attribute, the
Loading
Loading
/* eslint-disable */
(function(w) {
$(function() {
// Toggle button. Show/hide content inside parent container.
Loading
Loading
/* eslint-disable */
/*= require blob/template_selector */
((global) => {
 
Loading
Loading
/* eslint-disable */
(function() {
this.BlobFileDropzone = (function() {
function BlobFileDropzone(form, method) {
Loading
Loading
/* eslint-disable */
 
/*= require blob/template_selector */
 
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment