Skip to content

How to set horizontal margin for google docs #1175

Answered by plinionaves
plinionaves asked this question in Q&A
Discussion options

You must be logged in to vote

I managed to solve it and the solution is very simple.

I was defined as margins in each table cell, example:

new TableCell({
  margins: {
    top: convertInchesToTwip(0.05),
    bottom: convertInchesToTwip(0.05),
    right: convertInchesToTwip(0.09),
    left: convertInchesToTwip(0.09),
  },
});

Just remove from cells, and move to the table itself:

new Table({
  margins: {
    top: convertInchesToTwip(0.05),
    bottom: convertInchesToTwip(0.05),
    right: convertInchesToTwip(0.09),
    left: convertInchesToTwip(0.09),
  },
});

And that's it! Running Perfectly on Google Docs Now!

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by plinionaves
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant