Yes this is a known issue. Currently previews are not supported inside of static libraries. As a workaround you could create a dynamic library or framework target in addition to the static library and put the file in both targets. Then, make sure your scheme is building the framework/dynamic library target even if it's not being included into any of your shipping apps, etc.
                    
                  
                
              
              
                
                Topic:
                  
	
		UI Frameworks
  	
                
                
                SubTopic:
                  
                    
	
		SwiftUI
		
  	
                  
                
              
              
                Tags: