Skip to content

Set-StrictMode -Version should support "off" as a parameter #16736

@Thomas-Yu

Description

@Thomas-Yu

Summary of the new feature / enhancement

Currently, Set-StrictMode -Version accepts "latest" to indicate the most recent version of StrictMode. It would be beneficial to also accept "off" and remove the Set-StrictMode -Off option. The "off" option would turn StrictMode to version 0.0

Usage: Set-StrictMode -Version off

Proposed technical implementation details (optional)

Invoke-Command -StrictMode allows "off" as a parameter.
Refer to this pull request #16545 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue-Enhancementthe issue is more of a feature request than a bugWG-Cmdlets-Corecmdlets in the Microsoft.PowerShell.Core module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions