Azure / Azure/bicep

Recommend/Autofix - Use Nested Resource Declaration

Open
#10,551 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Bicep
Stars
3.6k
Forks
830
Avg merge
1d 21m
Merged PRs (30d)
79

Description

A static analysis issue should detect when a nested resource declaration could be used and provide an autofix for this.

I should also be able to fix the entire file at once if there are multiple resources linked as parents.

If there are certain edge cases where this is not the recommend approach those should be detected and allowed.

Use nested resource declaration with existing to reduce the nested templates.

_Originally posted by @dciborow in https://github.com/Azure/bicep-registry-modules/pull/322#discussion_r1178490272_

Contributor guide

Open the contributing guide

Research direction

Start by locating the static-analysis rule for nested resource declarations and the existing autofix infrastructure. Define which parent-linked resources can use nested declarations, support fixing all eligible resources in a file, and verify that documented edge cases remain unchanged.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.