# Associating snippets with modules

**URL:** <https://forums.swift.org/t/associating-snippets-with-modules/59348>\
**Category:** Swift-DocC\
**Created:** [July 31, 2022, 7:15pm UTC](https://forums.swift.org/t/associating-snippets-with-modules/59348 "2022-07-31T19:15:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![taylorswift](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/taylorswift/32/43413_2.png) [@taylorswift](https://forums.swift.org/u/taylorswift)\
**Post date:** [July 31, 2022, 7:15pm UTC](https://forums.swift.org/t/associating-snippets-with-modules/59348/1 "2022-07-31T19:15:47Z")

</div>

as far as i can tell, SPM snippets are a package-level construct, as they all reside in a global snippets directory.

when generating a documentation archive for each target in a package, which target should receive the snippets? moreover, the snippets depend on the package’s library targets, and yet the doc-comments in the library targets must depend on the snippets in order to include them, which makes for a circular dependency.
