Guest User

Untitled

a guest
Oct 15th, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.71 KB | None | 0 0
  1. bjlewis2 [Oct 12th at 7:24 PM]
  2. Anybody ever successfully documented a pattern variation in PL?
  3. I have:
  4. ```
  5. menu-block.twig
  6. menu-block.yml
  7. menu-block.md <-- works
  8. menu-block~footer.yml <-- works
  9. menu-block~footer.md <-- doesn't work :(
  10. ```
  11.  
  12.  
  13. 6 replies
  14. Johnny5th [3 days ago]
  15. no, I think I tried that once. There was something else that the variations wouldn’t do, but I forgot what it was :confused:
  16.  
  17.  
  18. bjlewis2 [3 days ago]
  19. okay. That seems to be the consensus :disappointed:
  20.  
  21.  
  22. danny_englander [3 days ago]
  23. @bjlewis2 Emulsify's "card" has a variation `card~bg.yml` but the md file does not have the `~` and it works. (`card-bg.md`) (edited)
  24. Screen Shot 2018-10-12 at 10.47.10 AM.png
  25.  
  26.  
  27.  
  28. bjlewis2 [3 days ago]
  29. Sweet! I got it. Looks like you can’t have numbers in the file names. (I have numbers in the yml files to order then visually)
  30.  
  31. Here’s what works for me:
  32. ```
  33. menu-block-footer-cta.md
  34. menu-block-footer.md
  35. menu-block.md
  36. menu-block.twig
  37. menu-block.yml
  38. menu-block~01-footer.yml
  39. menu-block~02-footer-cta.yml
  40. ```
  41.  
  42.  
  43. However, the md file looks like it takes precedence over the yml file’s order, so they’re showing in the opposite order that I want them. (edited)
  44.  
  45.  
  46. bjlewis2 [3 days ago]
  47. Huzzah! You can add the number to the beginning of the md file to order them!
  48.  
  49. So, this works, and shows them in the order I want:
  50. ```
  51. 01-menu-block.md
  52. 02-menu-block-footer.md
  53. 03-menu-block-footer-cta.md
  54. menu-block.twig
  55. menu-block.yml
  56. menu-block~footer-cta.yml
  57. menu-block~footer.yml
  58. ```
  59.  
  60.  
  61. (I removed the numbers from the yml files since that doesn’t do anything anymore)
  62.  
  63. P.S. If you are just using the yml files, and add numbers to order them, the number _has_ to come after the `~` otherwise it’ll say “I can’t find the component `01-whatever.twig`
Add Comment
Please, Sign In to add comment