29 lines
676 B
Plaintext
Raw Normal View History

2021-04-28 16:49:39 +02:00
Re-exporting is a feature that allows a file to import a component (object, function or primitive) from a module and add it to the exported components of the file's module. However, as the language allows a file to export a component without explicitly importing it, a reader may mistake a re-export with a simple export.
2021-04-28 16:49:39 +02:00
== Noncompliant Code Example
----
export { foo } from 'someModule';
----
2021-04-28 16:49:39 +02:00
== Compliant Solution
----
import { foo } from 'someModule';
export { foo };
----
ifdef::env-github,rspecator-view[]
'''
== Implementation Specification
(visible only on this page)
include::message.adoc[]
include::highlighting.adoc[]
endif::env-github,rspecator-view[]