- 17 Nov, 2016 40 commits
-
-
Allison Whilden authored
Update copy.md with issue guideline updates and merge request guidelines Update copy.md with issue guideline updates and merge request guidelines See merge request !7513
-
Victor Wu authored
Update examples and labels to use sentence case. Update copy.md [ci skip] Update copy.md [ci skip] Update copy.md
-
Achilleas Pipinellis authored
Fix missing URL from environments docs See merge request !7542
-
Achilleas Pipinellis authored
[ci skip]
-
Annabel Dunstone Gray authored
Fix line numbers not matching up with code in Firefox. Firefox has had broken line number alignment for a while now, if this is a bug with Firefox they don't seem to want to fix it since its been there from 46 through 49. This fixes it. Before: ![Screen_Shot_2016-09-22_at_3.08.44_PM](/uploads/8bb65f40e44f738c0c375b0c8ef7dea6/Screen_Shot_2016-09-22_at_3.08.44_PM.png) After: ![Screen_Shot_2016-09-22_at_3.09.10_PM](/uploads/9e537be56886569d8a82390f2b97c42b/Screen_Shot_2016-09-22_at_3.09.10_PM.png) Fixes #20202. Safari/Chrome work the same as before, Snippets seems to work fine still as well. Page tested: http://localhost:3000/gitlab-org/gitlab-ce/blob/master/app/models/project.rb cc: @annabeldunstone See merge request !6485
-
Jacob Schatz authored
Decide on and document a convention for singletons > The singleton pattern is a design pattern that restricts the instantiation of a class to one object. This is useful when exactly one object is needed to coordinate actions across the system. The simplest implementation uses an object literal to contain the logic. ```javascript gl.MyThing = { prop1: 'hello', method1: () => {} }; ``` A live example of this is [GfmAutoComplete](https://gitlab.com/gitlab-org/gitlab-ce/blob/172aab108b875e8dc9a5f1d3c2d53018eff76ea1/app/assets/javascripts/gfm_auto_complete.js.es6) Another approach makes use of ES6 `class` syntax. ```javascript let singleton; class MyThing { constructor() { if (!singleton) { singleton = this; singleton.init(); } return singleton; } init() { this.prop1 = 'hello'; } method1() {} } gl.MyThing = MyThing; ``` A live example of this is [Sidebar](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/app/assets/javascripts/sidebar.js.es6) Another functional approach to define Singleton using `Javascript Revealing Module Pattern` is like below ```javascript /** * 1. It instantiates only a single object * 2. It is safe – it keeps the reference to the singleton inside a variable, which lives inside a lexical closure, so it is not accessible by the outside world * 3. It allows privacy – you can define all private methods of your singleton inside the lexical closure of the first module pattern * 4. No this keyword trap (no wrong context referring) * 5. No use of new keyword * 6. Easy to write test code */ // const Singleton = (function () { // Instance stores a reference to the Singleton var instance; function init() { // Singleton // Private methods and variables function privateMethod(){ console.log( "I am private" ); } var privateVariable = "Im also private"; var privateRandomNumber = Math.random(); return { // Public methods and variables publicMethod: function () { console.log( "The public can see me!" ); }, publicProperty: "I am also public", getRandomNumber: function() { return privateRandomNumber; } }; }; return { // Get the Singleton instance if one exists // or create one if it doesn't getInstance: function () { if ( !instance ) { instance = init(); } return instance; } }; })(); const singletonObj = Singleton.getInstance() ``` ## Are there points in the code the reviewer needs to double check? ## What does this MR do? Creates a space for discussion and contribution for interested devs. ## Why was this MR needed? ## Screenshots (if relevant) ## Does this MR meet the acceptance criteria? - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [x] All builds are passing (http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? See merge request !6620
-
Sean McGivern authored
Fixing the issue of visiting a project fork url giving 500 error when not signed… Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/24302 See merge request !7392
-
Sean McGivern authored
Support subscribing to group labels https://gitlab.com/gitlab-org/gitlab-ce/issues/23586 See merge request !7215
-
Rémy Coutable authored
Allows to authorize chat user against GitLab. This is needed for: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/7438 See merge request !7450
-
Kamil Trzciński authored
Remove unused CI gems See merge request !7522
-
Robert Speicher authored
Start to document how to code for CE with EE in mind Closes #23740 [ci skip] See merge request !7248
-
Rémy Coutable authored
Signed-off-by: Rémy Coutable <remy@rymai.me>
-
Rémy Coutable authored
[ci skip] Signed-off-by: Rémy Coutable <remy@rymai.me>
-
Rémy Coutable authored
-
Rémy Coutable authored
[ci skip] Signed-off-by: Rémy Coutable <remy@rymai.me>
-
Fatih Acet authored
Include author in assignee dropdown search ## What does this MR do? Previously when you searched for the author in the assignee dropdown (if they aren't in the project) it did not actually include the author. This changes that so that when you search for the author it will correctly include the user. ## Screenshots (if relevant) ![Screen_Shot_2016-11-17_at_11.14.53](/uploads/5a13475d8ded459fd3b1ba6570897665/Screen_Shot_2016-11-17_at_11.14.53.png) ## What are the relevant issue numbers? Closes #22905 See merge request !7526
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-
Douglas Barbosa Alexandre authored
-