Ionide-vscode-fsharp: PascalCase identifiers

Created on 24 Aug 2016  路  7Comments  路  Source: ionide/ionide-vscode-fsharp

Hi there,

I would prefer camelCase identifiers. Who decided it should be PascalCase? Nowadays ionide complains and I'm enforcing camelCase throughout my projects.

Regards,
Henrik

Moved from https://github.com/ionide/ionide-atom-fsharp/issues/251

Most helpful comment

I'd really like to be able to disable specific Linter rules, specifically for Fable.
Example:

    type IJQuery =
        abstract css : string * string -> IJQuery
        abstract addClass : string -> IJQuery
        [<Emit("$0.click($1)")>]
        abstract click : (obj -> unit) -> IJQuery
        [<Emit("$0.click()")>]
        abstract click : unit -> IJQuery
        [<Emit("$0.on('click', $1)")>]
        abstract onClick : (obj -> unit) -> IJQuery

All 7 comments

this linting rule is from FSharplint, @duckmatt wrote it
I turn it off, you can too

    // Enables integration with FSharpLinter (additional warnigns)
    "FSharp.linter": false,

If @Krzysztof-Cieslak had included settings support you could turn off that particular rule, but he did not

Thanks

If @Krzysztof-Cieslak had included settings support you could turn off that particular rule, but he did not

I included settings support, you can turn off rules using FSharpLint setting file.

Hi @Krzysztof-Cieslak,

I just saw someone hit this problem (see https://github.com/fsprojects/FSharpLint/issues/180).

There are three things I see

  • The FSharpLint message is too strong. It says you _mut_ use Pascal case identifiers. This should say something softer like "suggest".
  • In Ionide, FSharpLint error messages should have text indicating that they are from FSharpLint. Currently they look like they are coming from F# proper. I know they use green squigglies - but beginners don't know that.
  • Also it would be very helpful to have Ionide automatically add some help text explaining how to adjust FSharpLint settings

Cheers
don

This is fixed in 2.5.3 - new version of FSharpLint includes new warning messages and we know add information that warning comes from Linter.

Also it would be very helpful to have Ionide automatically add some help text explaining how to adjust FSharpLint settings

I will consider it, not yet sure how to do this way without putting too intrusive messages.

@Krzysztof-Cieslak Thanks!

I'd really like to be able to disable specific Linter rules, specifically for Fable.
Example:

    type IJQuery =
        abstract css : string * string -> IJQuery
        abstract addClass : string -> IJQuery
        [<Emit("$0.click($1)")>]
        abstract click : (obj -> unit) -> IJQuery
        [<Emit("$0.click()")>]
        abstract click : unit -> IJQuery
        [<Emit("$0.on('click', $1)")>]
        abstract onClick : (obj -> unit) -> IJQuery
Was this page helpful?
0 / 5 - 0 ratings