-
Notifications
You must be signed in to change notification settings - Fork 126
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We want to be able to import page variables that resides in inner files. For example, given the following code: <include src="foo.md#title" /> {{ title }} which will import the variable inside foo.md: <variable name="title">Title</variable> Let's implement this feature.
- Loading branch information
Showing
6 changed files
with
142 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Imported Variable | ||
<import src="testImportedVariablesToImport.md#imported_variable" /> | ||
{{ imported_variable }} | ||
|
||
# Imported Variable Referencing Global Variable | ||
<import src="testImportedVariablesToImport.md#imported_variable_referencing_global_variable" /> | ||
{{ imported_variable_referencing_global_variable }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# **Should not appear**: Imported Variable | ||
<variable name="imported_variable">Imported Variable</variable> | ||
|
||
# **Should not appear**: Imported Variable on Top Level | ||
<variable name="imported_variable_on_top_level">Imported Variable on Top Level</variable> | ||
|
||
# **Should not appear**: Imported Variable Referencing Global Variable | ||
<variable name="imported_variable_referencing_global_variable">Imported Variable Referencing {{ global_variable }}</variable> |