diff options
| author | Adam <adam@adambard.com> | 2016-01-08 14:35:53 +0800 | 
|---|---|---|
| committer | Adam <adam@adambard.com> | 2016-01-08 14:35:53 +0800 | 
| commit | ef28fa69775ba064dfed212e034b5caae7edb7b9 (patch) | |
| tree | d3a30be274822754414b438fe9b9c102edc09630 /fr-fr | |
| parent | 8ad537a9ba9889234a63c5a38caeab3e225856e4 (diff) | |
| parent | 04166190367a93236e7173901dff7ae9661736ba (diff) | |
Merge branch 'master' of github.com:adambard/learnxinyminutes-docs
Diffstat (limited to 'fr-fr')
| -rw-r--r-- | fr-fr/go-fr.html.markdown | 2 | ||||
| -rw-r--r-- | fr-fr/typescript-fr.html.markdown | 58 | 
2 files changed, 30 insertions, 30 deletions
diff --git a/fr-fr/go-fr.html.markdown b/fr-fr/go-fr.html.markdown index 16558e7e..9d8bef70 100644 --- a/fr-fr/go-fr.html.markdown +++ b/fr-fr/go-fr.html.markdown @@ -3,7 +3,7 @@ name: Go  category: language  language: Go  lang: fr-fr -filename: learngo.go +filename: learngo-fr.go  contributors:      - ["Sonia Keys", "https://github.com/soniakeys"]      - ["Christopher Bess", "https://github.com/cbess"] diff --git a/fr-fr/typescript-fr.html.markdown b/fr-fr/typescript-fr.html.markdown index b8807104..52d34650 100644 --- a/fr-fr/typescript-fr.html.markdown +++ b/fr-fr/typescript-fr.html.markdown @@ -87,22 +87,22 @@ mySearch = function(src: string, sub: string) {  // Les membres des classes sont publiques par défaut.  class Point { -    // Propriétés -    x: number; - -    // Constructeur - Les mots clés "public" et "private" dans ce contexte -    //  génèrent le code de la propriété et son initialisation dans le -    // constructeur. Ici, "y" sera défini de la même façon que "x", -    // mais avec moins de code. Les valeurs par défaut sont supportées. -    constructor(x: number, public y: number = 0) { -        this.x = x; -    } +  // Propriétés +  x: number; + +  // Constructeur - Les mots clés "public" et "private" dans ce contexte +  //  génèrent le code de la propriété et son initialisation dans le +  // constructeur. Ici, "y" sera défini de la même façon que "x", +  // mais avec moins de code. Les valeurs par défaut sont supportées. +  constructor(x: number, public y: number = 0) { +    this.x = x; +  } -    // Fonctions -    dist() { return Math.sqrt(this.x * this.x + this.y * this.y); } +  // Fonctions +  dist() { return Math.sqrt(this.x * this.x + this.y * this.y); } -    // Membres statiques -    static origin = new Point(0, 0); +  // Membres statiques +  static origin = new Point(0, 0);  }  var p1 = new Point(10 ,20); @@ -110,17 +110,17 @@ var p2 = new Point(25); // y sera 0  // Héritage  class Point3D extends Point { -    constructor(x: number, y: number, public z: number = 0) { -        // Un appel explicite au constructeur de la super classe -        // est obligatoire. -        super(x, y); -    } +  constructor(x: number, y: number, public z: number = 0) { +    // Un appel explicite au constructeur de la super classe +    // est obligatoire. +    super(x, y); +  } -    // Redéfinition -    dist() { -        var d = super.dist(); -        return Math.sqrt(d * d + this.z * this.z); -    } +  // Redéfinition +  dist() { +    var d = super.dist(); +    return Math.sqrt(d * d + this.z * this.z); +  }  }  // Modules, "." peut être utilisé comme un séparateur de sous modules. @@ -144,19 +144,19 @@ var s2 = new G.Square(10);  // Génériques  // Classes  class Tuple<T1, T2> { -    constructor(public item1: T1, public item2: T2) { -    } +  constructor(public item1: T1, public item2: T2) { +  }  }  // Interfaces  interface Pair<T> { -    item1: T; -    item2: T; +  item1: T; +  item2: T;  }  // Et fonctions  var pairToTuple = function<T>(p: Pair<T>) { -    return new Tuple(p.item1, p.item2); +  return new Tuple(p.item1, p.item2);  };  var tuple = pairToTuple({ item1:"hello", item2:"world"});  | 
